comparison m-toolbox/classes/+utils/@helper/num2str.m @ 0:f0afece42f48

Import.
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 23 Nov 2011 19:22:13 +0100
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:f0afece42f48
1 function str = num2str(number)
2 % NUM2STR uses sprintf to convert a data vector to a string with a fixed precision.
3 %
4 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
5 %
6 % DESCRIPTION: uses sprintf to convert a data vector to a string with a fixed precision.
7 %
8 % CALL: str = num2str(number);
9 %
10 % VERSION: $Id: num2str.m,v 1.1 2008/06/18 13:35:12 hewitson Exp $
11 %
12 % HISTORY: 18-10-2007 Hewitson
13 % Creation
14 %
15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
16
17
18 str = sprintf('%.17g ', number);
19