From: vgsangiuliano Poretti on 3 Apr 2010 04:35 Hi to all, Can anyone say me how to use a field of a struct variable as a counter for a FOR cicle? When I use for x.test=1:1:10 I get | Error: Unexpected MATLAB operator. of course using for x=1:1:10 is correct Thank you
From: us on 3 Apr 2010 04:43 "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6uk8$e2j$1(a)fred.mathworks.com>... > Hi to all, > Can anyone say me how to use a field of a struct variable as a counter for a FOR cicle? > > When I use > > for x.test=1:1:10 I get > > | > Error: Unexpected MATLAB operator. > > of course using for x=1:1:10 is correct > > Thank you a hint: - there's no solution: this syntax simply does not work... us
From: vgsangiuliano Poretti on 3 Apr 2010 04:47 "us " <us(a)neurol.unizh.ch> wrote in message <hp6v2p$jq6$1(a)fred.mathworks.com>... > "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6uk8$e2j$1(a)fred.mathworks.com>... > > Hi to all, > > Can anyone say me how to use a field of a struct variable as a counter for a FOR cicle? > > > > When I use > > > > for x.test=1:1:10 I get > > > > | > > Error: Unexpected MATLAB operator. > > > > of course using for x=1:1:10 is correct > > > > Thank you > > a hint: > - there's no solution: this syntax simply does not work... > > us Thank you for reply So isn't there any way to do that?
From: us on 3 Apr 2010 04:54 "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6vaq$n0a$1(a)fred.mathworks.com>... > "us " <us(a)neurol.unizh.ch> wrote in message <hp6v2p$jq6$1(a)fred.mathworks.com>... > > "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6uk8$e2j$1(a)fred.mathworks.com>... > > > Hi to all, > > > Can anyone say me how to use a field of a struct variable as a counter for a FOR cicle? > > > > > > When I use > > > > > > for x.test=1:1:10 I get > > > > > > | > > > Error: Unexpected MATLAB operator. > > > > > > of course using for x=1:1:10 is correct > > > > > > Thank you > > > > a hint: > > - there's no solution: this syntax simply does not work... > > > > us > > Thank you for reply > So isn't there any way to do that? ???... did you read and comprehend what i just wrote(?)... us
From: vgsangiuliano Poretti on 3 Apr 2010 04:58 "us " <us(a)neurol.unizh.ch> wrote in message <hp6vnd$rvv$1(a)fred.mathworks.com>... > "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6vaq$n0a$1(a)fred.mathworks.com>... > > "us " <us(a)neurol.unizh.ch> wrote in message <hp6v2p$jq6$1(a)fred.mathworks.com>... > > > "vgsangiuliano Poretti" <vgsangiuliano(a)gmail.com> wrote in message <hp6uk8$e2j$1(a)fred.mathworks.com>... > > > > Hi to all, > > > > Can anyone say me how to use a field of a struct variable as a counter for a FOR cicle? > > > > > > > > When I use > > > > > > > > for x.test=1:1:10 I get > > > > > > > > | > > > > Error: Unexpected MATLAB operator. > > > > > > > > of course using for x=1:1:10 is correct > > > > > > > > Thank you > > > > > > a hint: > > > - there's no solution: this syntax simply does not work... > > > > > > us > > > > Thank you for reply > > So isn't there any way to do that? > > ???... did you read and comprehend what i just wrote(?)... > > us Sure I understood, I only thought that my way was wrong but maybe there was another way to get the same result. So if no way, I will change my code using the counter not being a field of a struc variable. Thank you
|
Next
|
Last
Pages: 1 2 Prev: setting upper bound and lower bounds in Optimization toolbox Next: need help with arrays |