help-octave
[Top][All Lists]
Advanced

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

Re: octave function


From: Ben Abbott
Subject: Re: octave function
Date: Sat, 28 May 2011 16:09:55 -0400

On May 28, 2011, at 3:02 PM, asdw wrote:

> HI!
> I'm in trouble with one function. 
> I have a vector of structures with time and concentrations of a chemical
> compound
> and I want to create a function that returns an array with the time and
> concentration but without the "[]" that appear in the vector of
> concentrations such as
> concentration
> 0.0
> 12:15
> []
> 00:20
> []
> 
> I did this
> function conc = c (table)
>   p = [];
>  for f = 1: length (conc)
>    conc = table (f). conc;
>   if conchs =="[]"
>     p = [p];
>     else
>    p = [p, table (f). conchs temperature table (f). min];
>  endif
>  endfor
>  endfunction
>    but it gives me error
> 
> table is the list of the vector structures of time and concentrations
> thank you


I see several problems, but can't determine how to fix them without more 
information.

Please tell us what you get when you type ...

        whos table
        table

Ben


reply via email to

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