# how to do the following logic in matlab from excel?

1 visualización (últimos 30 días)
Vishnuvardhan Naidu Tanga el 28 de Oct. de 2021
Comentada: Vishnuvardhan Naidu Tanga el 28 de Oct. de 2021
Hello all,
I am new to matlab. I am trying to perform a logic in matlab. The log is available in excel wich is as follows.
2pirdr = 2*H\$2*0.5*(A2+A3)*(A2-A3)*0.000001*0.5*(B2+B3) and vflow = =D3+C2 for negative coloumn1 and
2pirdr = =2*H\$2*0.5*(A60+A59)*(A60-A59)*0.000001*0.5*(B59+B60) and vflow = =D59+C60 for positive coloumn1
##### 0 comentariosMostrar -2 comentarios más antiguosOcultar -2 comentarios más antiguos

Iniciar sesión para comentar.

LeoAiE el 28 de Oct. de 2021
Editada: LeoAiE el 28 de Oct. de 2021
Hi,
First step is to Clean your data and name your columns something won’t confuse MATALB something like Radius, Velocity, 2pirdr and Vflow. Next get rid of the Pi value. MATLAB already have pi just type pi. then import your file in MATALB
Now, use indexing to replace your A3, A2, B2 etc. Cell numbers in excel minus one
vflow = =Data.Vflow(2)+ Data.2pirdr(1);
% now you should consider changing the variables names instead of
% overwriting them like
vflow_2 = Data.Vflow(58)+Data.2pirdr(59);
I'm not sure if this is the logic you are looking for or you have something else in mind. You can easily separate the negative values from the positives values in two different tables and do all kind of operations there.
##### 1 comentarioMostrar -1 comentarios más antiguosOcultar -1 comentarios más antiguos
Vishnuvardhan Naidu Tanga el 28 de Oct. de 2021

Iniciar sesión para comentar.

### Categorías

Más información sobre Data Import from MATLAB en Help Center y File Exchange.

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by