Question

Plot with mean and std of variables
I have a basic plot as follows. How can I display mean and std of X, Y, and Z in the legend? Plot1=plot(T,X) hold o...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Representation of Y axis grid
When I draw a plot, y axis has grids of 0, 1, 2, 3 * 10^5. This is not very easy to understand. Thus I would like to have grids ...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Put a new variable at the top of a table
I create a new variable a at table T. When I try to view T using viewer, a will be at the end (the most right) of the screen. Is...

meer dan een jaar ago | 2 answers | 0

### 2

Question

Key variable renamed after outerjoin
I outerjoin two tables A and B with the key variable "date". I find that the resulting table has variables name date_A and date_...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Plot: dealing with data available only on weekdays
I want to plot X (date), Y, and Z. Y has an entry for every day but Z has entry only for weekdays (not weekends). Will the code ...

meer dan een jaar ago | 1 answer | 0

### 1

Question

define a color for plot
I create a plot such as Plot1=plot(Date,A,'Color',[0.1112456 0.2098437 0.31116789],'LineWidth',1.2) Now I want to define...

meer dan een jaar ago | 2 answers | 0

### 2

Question

Plot with a lag, Part 2
In a previous question <https://www.mathworks.com/matlabcentral/answers/404779-plot-with-a-lag> "Suppose I want to have plot ...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Plot with a lag
Suppose I want to have plot of lagged x and y that belong in table T. For example, I want to have a plot that the first element ...

meer dan een jaar ago | 2 answers | 0

### 2

Question

Color of plots when there are multiple plots
I draw multiple plots using hold on Plot61=plot(Date,A,'LineWidth',1.2) hold on Plot62=plot(Date,B,'LineWidth...

meer dan een jaar ago | 2 answers | 0

### 2

Question

fitlm on timetable: error message
I try to run fitlm on a time table. I checked dependent and independent variables and got following outputs ans = ...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Extract a table with some range of dates
Suppose I have a table with date from 2000 to 2018. I want to create a new table where the date is between Jan 1 2010 and Dec 31...

meer dan een jaar ago | 1 answer | 0

### 1

Question

plot with a limited range of x
I would like to plot (x,y) where x is dates from 2000 to 2018. I would like to plot only for x from Jan 1 2010. Please advise ho...

meer dan een jaar ago | 1 answer | 0

### 1

Question

picking maximum difference across entries of row vectors, Part 3
This is a follow-up with a previous question. <https://www.mathworks.com/matlabcentral/answers/404403-picking-maximum-difference...

meer dan een jaar ago | 1 answer | 0

### 1

Question

picking maximum difference across entries of row vectors, Part 2
I would like to generalize the previous question ( <https://www.mathworks.com/matlabcentral/answers/404240-picking-maximum-diffe...

meer dan een jaar ago | 2 answers | 0

### 2

Question

Rename all variables in table
Suppose I have a table T about New York with variables a,b,c.... I would like to rename all variables in T as 'NYa",'NYb',.... e...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Readtable error: Index exceeds array bounds.
I ran readtable as in the following command: E = readtable('C:\Dropbox\Matlab\AAA\BBB.csv'); and got the following error...

meer dan een jaar ago | 1 answer | 0

### 1

Question

outer join of multiple tables
I have multiple (about 15) csv files that I would like to outerjoin. I would like to know whether there is a simple way to write...

meer dan een jaar ago | 0 answers | 0

### 0

Question

picking maximum difference across entries of row vectors
I have a matrix A. I would like to create a column vector B that is for each row, take a difference between every possible pa...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Extracting the data from a column vector according to mod
I have a column vector x. I want to create a vector x1 that are the 1st, 5th, 9th, ... elements of x, x2 that are the 2nd, 6th, ...

meer dan een jaar ago | 3 answers | 0

### 3

Question

Add a variable to a table
Suppose I have a table T. I want to add a variable x to T. Please advise the steps.

meer dan een jaar ago | 1 answer | 0

### 1

Question

running fitlm with calculation of variables in a table
Suppose I have a table with variables x, y, and z. I want to run a regression with y = a = n*(x/z) please advise how to...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Plot where x axis is the date, Part 2 (edited)
I would like to have x axis of the plot between April 20 2016 and May 18 2018. Please advise how to modify an example xlim...

meer dan een jaar ago | 3 answers | 0

### 3

Question

Plot where x axis is the date
In my plot x axis is the date starting from 04/20/2018 and ending 06/01/2018. How can I set the x axis of the plot to start from...

meer dan een jaar ago | 1 answer | 0

### 1

Question

ismember error message "Subscript indices must either be real positive integers or logicals."
I have two matrices A and B, and the desired output in an attached csv file. To obtain the desired outcome I have run [~,lo...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Calculation of conditional expectations
Suppose I have a vector A and I would like to calculate the sum of the elements in A divided by the number of positive elements ...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Creating a matrix of marginal distributions from a matrix of joint distributions
I would like to create a matrix of marginal distributions from a matrix of joint distributions. As a specific example, suppos...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Editor and command windows next to each other, Part 3
Now I have two windows side by side. What will be the steps to make this setting to be a default setting (i.e. whenever one open...

meer dan een jaar ago | 1 answer | 0

### 1

Question

matrix when logging with "diary" command
When I save an output using "diary" command, I get an output that there are line breaks for each two columns. But I would like t...

meer dan een jaar ago | 0 answers | 0

### 0

Question

Diary file with current date and time as time stamp, Part 2
To follow up with "Diary file with current date and time as time stamp," % Turn On Diary Logging diary off % first t...

meer dan een jaar ago | 1 answer | 0

### 1

Question

Save workspace output to a file, part 2
Suppose I have a code as follows a=1; fprintf('value of a is %f \n',a) b=2; fprintf('value of b is %f \n',...

meer dan een jaar ago | 0 answers | 0