Réponse apportée
read file txt with strings and numbers
Use readtable or readcell, depending on what you want. There are other options (textscan), however those two are easiest to use...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Equation with constants and two variables that are ranges of values
Try this — Beta=(0.0:0.10:1.0); T=(473.15:100:1473.15); BigDeltaPlgH2O = (2.91-0.76*Beta) .* (10^6./T.^2) - 3.41 - 0.41*Beta...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
how do you offset curves?
Was my answer to your previous post How to invert axes? helpful? In: subplot(2,2,2, 'align'); if you want the time vector ...

environ 3 ans il y a | 1

Réponse apportée
How to invert axes?
I believe what you want is Reverse — x = linspace(0, 1); y = exp(-(x-0.5).^2*50); figure plot(x, y) grid figure plo...

environ 3 ans il y a | 1

| A accepté

Réponse apportée
How to remove incorrect tags from questions?
In the right margin of this page (and the page you want to change), there is a section called (appropriately) Tags. Just to the...

environ 3 ans il y a | 0

Réponse apportée
How to code NESTED CYCLES
I would set the empty array to 1 (so that it iterates one time only) and be done with it — a = @(x,y) [x y]; f = [3 6 3 9];...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Determining Signal to Noise Ratio
Calculating SNR can be difficult if the underlying signal is unknown. An extended discussion is in the Analyzing Harmonic Disto...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
How can I solve for specific complex solutions?
I am not certain what you want. The first step in solving this is to plot the functions. They may either guide you to a solu...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Dealing with transfer function in symbolic math toolbox.
Yes. Once you have the symbolic polynomials in , use the sym2poly function to extract the coefficiinets. (It may be necesary...

environ 3 ans il y a | 1

| A accepté

Réponse apportée
What stat test to use for improved task?
Theis seems to me to ba a paired test, so the Wilcoxon signed rank test (the signrank function) would likely be appropriate. ...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Fitting PDE to estimate parameters
I see one problem: residual = Ccalc - Cexp; that is easily fixed by using the norm function (here calculating the square root...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Averaging a curve with itself
Try this — % type('membrane_intensity.m') LD = load('test.mat'); x = LD.cx; y = LD.c(:,1,1); [xs,x1] = min(x); [xe,x2...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
how write legend plot right side)
Try this — x = linspace(0, 10); y = randn(size(x,2), 5); figure plot(x, y) legend(compose('Vector %2d',1:5), 'Location',...

environ 3 ans il y a | 1

| A accepté

Réponse apportée
Replacing elements in arrays
I am not exactly certain what you want to do, what the nubmers are, or if you only want to replace one or all that meet the crit...

environ 3 ans il y a | 0

Réponse apportée
Detrending still leaves a slope
This is the best I can do with your data. A reasonably robust approach is — % imshow(imread('lineprofile.jpg')) % imshow(i...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Fourier analysis of an spwm signal
Try this — LD = load('spwm_one_cycle.mat') ts1 = LD.ts1 Time = ts1.Time; Data = ts1.Data; figure plot(Time, Data) xl...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
How to change x-axis without changing datapoints?
Here are two ways of changing the plot — x = linspace(536000, 543000, 500).'; yax = linspace(532900, 533400, 500).'; B =...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
An EEG dataset .txt , I want to transpose the rows and columns for all files.
I would still keep them as they are in the files, and transpose them after you read the files. EEG = readmatrix('S9 HC.txt') ...

environ 3 ans il y a | 1

Réponse apportée
How to import range of text files into different matrices?
I do not know anything about the file contents, so the easiest way would be to save them to cell array elements. D = cell(50,...

environ 3 ans il y a | 0

Réponse apportée
I have an error saying 'Operator '*' is not supported for operands of type 'function_handle'." and I do not know what to do.
Function handle calls need to be evaluated. You code came close, however the syntax did not allow them to actually be evaluate...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Arrays have incompatible sizes for this operation.
The problem is: v = logspace(6, 11, 1000); % Using logspace for a smoother frequency range since everything else has a length...

environ 3 ans il y a | 1

| A accepté

Réponse apportée
Poctave bars next to each other
I cannot replicate your results with my prototype signal. The current ‘BarLayout’ property in your plot is 'stacked'. You ne...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Smoothing 3D surface plot and its color gradient
Experiment with the daspect function — filename = 'Data.csv'; data = readmatrix(filename); x = data(:, 1); y = data(:, 2)...

environ 3 ans il y a | 1

| A accepté

Réponse apportée
Pre-processing Data (PRV Signals)
The Signal Processing Toolbox resample function is specifically intended for signal processing and incorporates anti-aliasing fi...

environ 3 ans il y a | 1

Réponse apportée
Trying to do a Laplace transform on a discontinuous function
I initially wanted to see if piecewise would work. It didn’t. This is the result I get using heaviside to define the areas o...

environ 3 ans il y a | 0

Réponse apportée
Plots multiple lines-of-best-fits instead of just one
The data are missing, so an exact solution is not currently possible. The additional lilne could be that you are plotting bot...

environ 3 ans il y a | 0

Réponse apportée
Data analysis - How to recognize local peaks/different areas?
It would help to have the data. It is relatively straightforward to get the start and end times and then store the relevant d...

environ 3 ans il y a | 2

| A accepté

Réponse apportée
Why do i get an error saying "Unrecognized function or variable 'x'."
You have not defined ‘x’ specifically in your calling script prior to calling the function. Try something like this — x = ...

environ 3 ans il y a | 0

Réponse apportée
Trouble importing data from folder
I’m not certain that I understand what you want to do. If you want the number from the file name, perhaps something like thi...

environ 3 ans il y a | 0

Réponse apportée
Linear Algebra Error: Matrix is close to singular or badly scaled.
I am not certain what you want to do. Consider using the pinv function.

environ 3 ans il y a | 0

| A accepté

Charger plus