help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: load matrix of string


From: Jordi Gutiérrez Hermoso
Subject: Re: load matrix of string
Date: Sat, 12 Mar 2011 09:30:20 -0600

On 12 March 2011 08:33, sauber89 <address@hidden> wrote:
> for example, in my data file, I have:
>
> hello
> boy
>
> and I want to have:
>
> data(1)
>  -> hello
> data(2)
> -> boy
>
> end of the example

Use cell arrays.

data = {"hello", "boy"}; data{1}, data{2}.

Look at the output of "save data data" to see how you would need to
format your data file so Octave can read it with the "load data"
command.

HTH,
- Jordi G. H.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]