Create a new variable
Mostrar comentarios más antiguos
Hi,
This is a beginners question!! I want to create a new variable: CUENEUTRALONSET that will have the same values than CUEONSETTIME whenever the conditions block and type are '1'
I have tried the following with no success at all:
if all (['Block' == 1, 'Type' == 1])
then CUENEUTRALONSET = CUEONSETTIME(:,1);
end
I have (80*1) double variables in my workplace imported as column vectors from excel: Block, CUEDURATION, CUEONSETTIME, IMAGEONSETTIME, Type
Any suggestion will be highly appreciated.
Thanks so much!!
Victoria
2 comentarios
Walter Roberson
el 14 de Mzo. de 2013
MATLAB does not use "then"
Victoria
el 14 de Mzo. de 2013
Respuestas (1)
Azzi Abdelmalek
el 14 de Mzo. de 2013
Editada: Azzi Abdelmalek
el 14 de Mzo. de 2013
all (['Block' == 1, 'Type' == 1]) is always false (=0)
5 comentarios
Victoria
el 14 de Mzo. de 2013
Azzi Abdelmalek
el 14 de Mzo. de 2013
Editada: Azzi Abdelmalek
el 14 de Mzo. de 2013
if Block==1 & Type==1
CUENEUTRALONSET = CUEONSETTIME(:,1);
end
Victoria
el 14 de Mzo. de 2013
Azzi Abdelmalek
el 14 de Mzo. de 2013
Editada: Azzi Abdelmalek
el 14 de Mzo. de 2013
What are values assigned to Block and Type variables? Can you give more informations about your code
Victoria
el 14 de Mzo. de 2013
Editada: Azzi Abdelmalek
el 14 de Mzo. de 2013
Categorías
Más información sobre Image Processing Toolbox en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!