回答済み
Regression tree and prediction equation
This model is probably nonsense, because of the linear dependencies that @dpb points out. But perhaps your real data will yield ...

約1ヶ月 前 | 0

| 採用済み

回答済み
Is there a way to use a loop to generate outputs for a section of data (like rows 1 through 206) and then moving on to doing the same for subsequent rows within the same loop?
A somewhat more "advanced" way -- but perhaps more intuitive -- would be to convert Data into a 3-dimensional array first, where...

約1ヶ月 前 | 0

回答済み
Is there a way to use a loop to generate outputs for a section of data (like rows 1 through 206) and then moving on to doing the same for subsequent rows within the same loop?
Here is one way: for ii = 1:100 indexToThisSection = (206*(ii-1)+1) : (206*ii); Stress=Data(indexToThisSection,...

約1ヶ月 前 | 0

回答済み
making normally distributed over Specific Range
It is not possible to have a normal distribution in a finite range. So, we are all left guessing what the author of this docume...

約1ヶ月 前 | 1

回答済み
How would I go about modifying a matrix of 1's and 0's, and converting that matrix to an image (or plot)
Here is another way, plotting circles. There are probably better ways to do this. It's a bit convoluted, because of the way matr...

約1ヶ月 前 | 1

| 採用済み

回答済み
How would I go about modifying a matrix of 1's and 0's, and converting that matrix to an image (or plot)
One simple option would be to make a heatmap using imagesc: active = [0 0 0; 1 0 0; 0 0 0]; imagesc(active) axis square

約1ヶ月 前 | 0

回答済み
How to plot rectangles using variables
Are you trying to plot 216 rectangle with that one line? If you look at the documentation, you will see that you cannot do that....

約1ヶ月 前 | 0

| 採用済み

回答済み
Can I use google colab for running matlab codes
I don't have a definitive answer for you, but I'm pretty confident that the answer is -- No. MATLAB is definitely not made avai...

約1ヶ月 前 | 0

| 採用済み

回答済み
I want to do bootstrap analysis by using 20*1 matrix.
One way is % Pretend input data M = rand(20,1); idx = randi(20,500,1); samples = M(idx);

約1ヶ月 前 | 0

| 採用済み

回答済み
I want to do bootstrap analysis by using 20*1 matrix.
If you have the Statistics and Machine Learning Toolbox, you can do % Pretend input data M = rand(20,1); samples = randsamp...

約1ヶ月 前 | 0

回答済み
Adding rows as a column
You really don't give enough detail about what you are trying to do. You are making us assume and/or guess too much. Maybe you ...

約1ヶ月 前 | 0

回答済み
How to get max of repeated values?
Here is one way; % Input C = [0.5000 0.5000 0.3000 1.0000 0.8000 0.3000 0.7000 0.7000 0.3000 0.4...

約1ヶ月 前 | 0

| 採用済み

回答済み
How to get a for to end just before Index exceeds the number of array elements?
This seems like homework, so I will give you a hint instead of just answering. It seems like according to the rules, the last e...

約2ヶ月 前 | 0

| 採用済み

回答済み
how to plot group box-lot with use of function multiple box-lot
multiple_boxplot is not built in to MATLAB. It looks like it is a user-contributed functoin that you can download from the File ...

約2ヶ月 前 | 0

| 採用済み

回答済み
Check if cell contains another cell
a{1}='1-v1'; a{2}='.*'; a{3}='3+v2'; a{4}={'this is a cell'}; cellfun(@iscell,a)

約2ヶ月 前 | 0

| 採用済み

回答済み
How to make constants global
The first google hit for searching global matlab is this documentation page on how to define global variables.

約2ヶ月 前 | 0

回答済み
surf plot of custom data
It looks like the data are there as you expect, and it is just a matter of zooming in to the correct part of the "landscape". He...

約2ヶ月 前 | 0

回答済み
How to set x axis limit while using semilogx
10^0 is 1 (not 0), so this works ... T = [0 10 100 1000 10000]; Y = [0 1 4 7 10]; semilogx(T, Y) axis([1 10000 0 12])

約2ヶ月 前 | 0

回答済み
Tengo esta figura, y deseo sombrear la región entre la linea amarrilla y la linea roja. Tal vez alguien pueda darme una idea de como hacerlo. Muchas gracias :)
Both the patch and fill functions are useful for doing this. See examples in the documentation.

約2ヶ月 前 | 0

回答済み
Create a new table with filtered rows
Here is one way. % Pretend data sports = categorical({'basketball';'volleyball';'basketball'}); num = [2;3;5]; % Put in a ...

約2ヶ月 前 | 0

回答済み
I get Arrays have incompatible sizes for this operation with an elseif statement what do i do?
The essence of your issue is that you are using a character array as input. When character arrays are compared with the equality...

約2ヶ月 前 | 1

回答済み
How to get the predicted variables name in LASSO function?
You only supplied the PredictorNames input in your call to LassoPlot, not to lasso itself. var_names_test = {'a1','a2','a3','a4...

約2ヶ月 前 | 1

| 採用済み

回答済み
Assign a line in every element of a 3d matrix
To replace all values of 10 with 101.543, you can do val(val==10) = 101.543; Maybe that helps?

約2ヶ月 前 | 0

回答済み
How do i use fminsearch to find the minimum or maximum of a function . x.^4-3.*x.*y+2.*y.^2
Did you try reading the documentation for fminsearch? The very first example is exactly like your problem. fun = @(x)(x(1)^4 - ...

約2ヶ月 前 | 0

回答済み
Why my answer is not aligned with the prompt?
You need to add a line feed. I'll use fprintf instead of input to illustrate: fprintf("1: This will split \n into two lines") ...

約2ヶ月 前 | 0

回答済み
Keep getting the error "not enoguh input arguments"
You call the free_space function like this: if not(free_space(player_input)) but the free_space function takes two arguments: ...

約2ヶ月 前 | 0

| 採用済み

回答済み
How to change plotted graph's line?
If you leave the marker symbol off, the plot command will default to using a solid line with no symbol. You can also just explic...

約2ヶ月 前 | 0

| 採用済み

回答済み
The end operator must be used within an array index expression
In your code, you have not yet created any variable named y, before you call this line: y(1:end-1) = y(2:end-1) Therefore, you...

約2ヶ月 前 | 2

回答済み
How plot data as histograms?
This is not a histogram. It is a stacked bar chart. Take a look at this documentation to see how to construct this type of chart...

約2ヶ月 前 | 0

| 採用済み

回答済み
Axes not reconizing figure handle
The problem seems to be specifically with the XLabel argument, and the error message is non-intuitive (at least to me). This wo...

約2ヶ月 前 | 1

さらに読み込む