Risposto
Automatically take folder directories of one level up
You can specify the full path to the directories you want to open rather than changing the directory that MATLAB is running in. ...

oltre 5 anni fa | 0

Risposto
Multiply/divided two tables
% suppose you have a table T1 and T2 you could do something like A = [T1.myColumnName1 T1.myColumnName2] B = [T2.myColumnName...

oltre 5 anni fa | 0

Risposto
How to unit test several different functions that take the same input arguments efficiently?
Here are a couple of possibilities You can pass function handles, and then make the function you are testing be one of the argu...

oltre 5 anni fa | 0

Risposto
For loop data extraction
You overwrite your t and soln values with each loop iteration. If you want to save those to use them later you need to put them ...

oltre 5 anni fa | 1

Risposto
How to read a specefic column of several xls file and create a matrix
The readmatrix function can be used to read in the.Use the range option to specify the column you want from each .xls file. Type...

oltre 5 anni fa | 1

| accettato

Risposto
Why do I keep getting this error message? Error using ./ Matrix dimensions must agree.
I can run your code without getting any error messages. Can you please be more specific about how to reproduce the error. Also w...

oltre 5 anni fa | 0

Risposto
How to format this Loop?
In your code above x and y are the same they are both assigned to Data(d,:) do you mean to have? x = Data(d,:); y ...

oltre 5 anni fa | 0

| accettato

Risposto
Phase Angle in Vortex-Induced Vibrations
If you have phase angle values theta and velocity values v you can just plot plot(v,theta) If you are asking how do you calcu...

oltre 5 anni fa | 0

Risposto
Polyfit returns the wrong correlation coeffcient when I try do a linear regression
I don't think you are plotting your fitted y values For example where you have fFMA = polyval(pFMA,subwFMA(:)); ...

oltre 5 anni fa | 0

| accettato

Risposto
How to make matlab show line of error in appdesigner
I see in the documentation that "stack is an N-by-1 struct array, where N represents the depth of the call stack" Is it possibl...

oltre 5 anni fa | 0

| accettato

Risposto
How to find unknown parameters from experimental data fitted to an equation?
If you have the Optimization Toolbox you can use the function lsqcurvefit for solving this problem. Type doc lsqcurvefit on your...

oltre 5 anni fa | 0

| accettato

Risposto
Real and Imaginary element Separation from square matrix and stacking into a vector
D = diag(A) L = triu(A,1) U = tril(A,-1) [D; real(U(:)); real(L(:))] is close but you still have zero elements in L and U to...

oltre 5 anni fa | 1

| accettato

Risposto
Why does the MATLAB plot show up with no function on it?
Your plot limits are outside of the range of the data. Also you don't have enough (or any data points) in the range of x that ...

oltre 5 anni fa | 0

Risposto
Continuous to Discrete time signal
You should just evaluate and save your values x_t once Then to get your discrete samples (assuming the discrete sample interva...

oltre 5 anni fa | 0

Risposto
How do i make plot like this?
You must first make a matlab function or script to evaluate your y(x) and then plot your values So something like % define con...

oltre 5 anni fa | 0

| accettato

Risposto
how to compare previous and next values in MATLAB?
You need to create a new variable, call it for example prevB. After each loop set prevB = B when you do your comparison compar...

oltre 5 anni fa | 0

Risposto
How do I create an array with the greatest values from two arrays?
C = max(A,B)

oltre 5 anni fa | 0

| accettato

Risposto
Extract columns from matrix based on a vectors values
I think this should do it for you: C = A(:,B)

oltre 5 anni fa | 0

| accettato

Risposto
create csv files by extracting data from a starting csv file
Without knowing all of the details of what is in your files it is hard to give a specific answer. However for general advice I w...

oltre 5 anni fa | 0

Risposto
Minimalizing mean absolute error through optimisation?
You should be able to frame this as a linear programming problem which can be solved using MATLAB's linprog function.

oltre 5 anni fa | 0

Risposto
How to define RDT function in Matlab?
You need to call the function with its arguments. You just typed rdt on the command line. You must first assign the variables y...

oltre 5 anni fa | 1

Domanda


How to ensemble average with periodic inputs using System ID toolbox?
I am using the System Identification Toolbox. In general, one advantage of using periodic input signals, such as PRBS, is the po...

oltre 5 anni fa | 0 risposte | 0

0

risposte

Risposto
Function Finds the Prime Factorization of An Integer Greater than 1
The matlab factor command does it one line. But maybe you have to do it yourself for a homework exercise? For example f = facto...

oltre 5 anni fa | 0

| accettato

Risposto
Find a number inside a matrix
There are probably more efficient ways to do this but one approach would be to utilize MATLAB's find function. If your matrix ...

oltre 5 anni fa | 0

Risposto
try ,catch, and continue commands in for loop, and storing for loop data in a matrix
It looks like you never assign C{k} unless there is an error. Maybe you should assign C{k} after the end statement that end the ...

oltre 5 anni fa | 0

Risposto
more non-singleton rhs dimensions
I'm thinking that you want to loop through your t values. You first assign t to the vector [30,60,90,120,150] but then reassign ...

oltre 5 anni fa | 0

| accettato

Risposto
Plotting using a for loop
You need to save your values to a vector you are just replacing a single scalar value

oltre 5 anni fa | 0

Risposto
Matrix dimensions must agree
Use strcmp for example if strcmp(Caso,'isotermico') A switch case expression can also be used nicely for this switch Caso ...

oltre 5 anni fa | 0

| accettato

Risposto
Why am I able to leave out the right-most arguments in a call to a function that doesn't need them under certain circumstances?
This is a feature. As long as you don't do a calculation within the function that needs the missing variables it will not throw ...

oltre 5 anni fa | 0

| accettato

Risposto
EXTRACT TABLE FROM DATA
You may have a different number of columns each time through the loop. You can't just stack them on top of each other if they d...

oltre 5 anni fa | 0

| accettato

Carica altro