Question

How to plot a "goal" into my plot?

This is only to do something cool in the plot but I am plotting the trajectory of a soccer ball and I thought it would be cool t...

2 mois ago | 1 answer | 0

Question

How do I shade the xy plane at z=0 of my plot and how to stop the plot after it passes z=0?

I have the following code: t = 0:0.0001:20; %time m = 0.4; %mass (kg) g = 9.8; %gravitational accel. (m/s^2) b = 0.44; %drag...

3 mois ago | 1 answer | 0

Question

How to solve coupled (differential) equations of motion using matlab?

I am trying to solve three equations of motion and then plot the displacement in 3-D but am having trouble figuring out how to d...

3 mois ago | 1 answer | 0

Question

Issues with for loop

I currently have this for loop in my code. Where RawDataMatrix is a 549x41 matrix. for i = 1:length(RawDataMatrix(:,1)) if...

7 mois ago | 1 answer | 0

Question

Changing portions of variable names

This may be a very simple question but I have been struggling with it for a bit and would appreciate the help. rawdatafile = di...

8 mois ago | 1 answer | 0

Question

Help forming loop to simplify my code

This is the code I currently have to pull and graph some data I have. As you can see it is the same code repeated 5 times for th...

8 mois ago | 1 answer | 0

Question

Help with a for loop and matrices

I currently have this code where SizeChem is a 24x7 matrix and newcolum is a 24x1 matrix. newcolumn = sum(SizeChem,2); for i...

8 mois ago | 1 answer | 0

Question

Help with matrix manipulation

I have the following in matrix form and I am trying to figure out how to the following: -Create column H -Then enter the fol...

8 mois ago | 2 answers | 0

Question

Help creating a loop

Attached is the code in question. Currently I have the variables 'th' and 'Io' currently at one value. I would like to change th...

8 mois ago | 1 answer | 0

Question

Can Matlab search through the current directory to find and import a file?

I have some scripts that do data analysis and I am hoping to write some preliminary code to go through the current folder and fi...

9 mois ago | 1 answer | 0

Question

Help creating a for loop

I am taking some data in a 28x6 matrix and I am wanting to create a for loop that takes the value in each position in and divide...

9 mois ago | 1 answer | 0

Question

Error message while using if statement

I am trying to create an if statement that will create a file "Rawdata" in my current directory but I also want it to check if t...

9 mois ago | 1 answer | 0

Question

How to take the average every 5 data points?

I have a matrix 'GoogleDateClose' that is 251 by 2. The first column is just 1-252 to give a number assigned to each value in co...

plus d'un an ago | 1 answer | 0

Question

How do I add std bars to the Graph I just created?

So I would like to add std bars to each individual value on this graph I made and am unsure how to do it. Here is the code I use...

plus d'un an ago | 0 answers | 0

Question

Why am I getting this error message?

function [STD] = STD(T4, T7, H2O, Temp4, Temp7, H2Onumb, HC) s4 = (T4/Temp4)^2; %std of T4 divided by the mean of T4 ...

plus d'un an ago | 1 answer | 0

Question

How do I use the command 'smooth' to smooth a plot of data I have pulled from two matrices?

Here is the code I used: if true cloudy = find(Tday > 312.38 & Tday < 312.91); T1smooth = smooth(Tmatrix(cloudy),'lowess'...

presque 2 ans ago | 1 answer | 0