10+ years of MatLab experience

Always interested in teaching others and learning new tricks.

Datasets changed the way I program in MatLab, I love them.

Professional Interests: Time series, Numerical Analysis, Forecasting, Option Pricing, Econometrics, Image Processing

Question

webread not working for JSON

I can read from url's and api's just fine as long as the return format is not JSON. Some examples from matlab help that don't wo...

6 years ago | 0 answers | 1

Answered

How to add folder automatically

This will create one in the working directory foldername='newfoldername' mkdir([pwd '\' foldername])

How to add folder automatically

This will create one in the working directory foldername='newfoldername' mkdir([pwd '\' foldername])

7 years ago | 0

Solved

Length of the hypotenuse

Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle. <<http://upload....

7 years ago

Solved

Is this triangle right-angled?

Given three positive numbers a, b, c, where c is the largest number, return *true* if the triangle with sides a, b and c is righ...

7 years ago

Question

dataset join between date range

I know how to do this in SQL but I can't think of the best way to accomplish it in matlab. I need to do is repeat the value for...

7 years ago | 0 answers | 0

Question

Fill NaNs in array with last value

Hi all, thanks for your help. I have a double array and I want to fill NaN values with the last value. Example: [321 na...

7 years ago | 2 answers | 2

Answered

LinearModel custom class questions

I think in order for you to have all the functionality of the class you need to keep the variable information. Can you just copy...

LinearModel custom class questions

I think in order for you to have all the functionality of the class you need to keep the variable information. Can you just copy...

7 years ago | 0

Answered

Removing entries of vector indexed by odd integer.

You just have to reference every other element of the vector you created. x=linspace(1.4, -3.5, 101) ; y=x(1:2:end); ...

Removing entries of vector indexed by odd integer.

You just have to reference every other element of the vector you created. x=linspace(1.4, -3.5, 101) ; y=x(1:2:end); ...

7 years ago | 1

| accepted

Answered

Issue with Cholesky decomposition and positive definiteness

I used Spectral decomposition when this happens. Which is just a fancy name for setting the negative eigenvalues to zero before ...

Issue with Cholesky decomposition and positive definiteness

I used Spectral decomposition when this happens. Which is just a fancy name for setting the negative eigenvalues to zero before ...

7 years ago | 1

Answered

LinearModel.fit results to array

I was able to do it, i made a dataset mid to hold everything md = LinearModel.fit() mid.RsqAdj=md.Rsquared.Adjusted; ...

LinearModel.fit results to array

I was able to do it, i made a dataset mid to hold everything md = LinearModel.fit() mid.RsqAdj=md.Rsquared.Adjusted; ...

7 years ago | 0

Answered

Eigenvalue Decomposition of Matrix that doesn't fit in memory

Not really, maybe principle component analysis is a better option.

Eigenvalue Decomposition of Matrix that doesn't fit in memory

Not really, maybe principle component analysis is a better option.

7 years ago | 0

Answered

Using a loop to write to excel

Count is not a cell array but you reference it as one using {i}

Using a loop to write to excel

Count is not a cell array but you reference it as one using {i}

7 years ago | 0

| accepted

Answered

How to use radio buttons more effectively in a button group?

In the radio button group callback you will need to either clear the axes or overwrite the data being displayed inside the obje...

How to use radio buttons more effectively in a button group?

In the radio button group callback you will need to either clear the axes or overwrite the data being displayed inside the obje...

7 years ago | 0

Answered

Data vusualization - How to align data sets?

I would probably do the circshift function and search for the highest correlation. But if the first minimum works wells then sti...

Data vusualization - How to align data sets?

I would probably do the circshift function and search for the highest correlation. But if the first minimum works wells then sti...

7 years ago | 0

| accepted

Question

count of months spanned

I can't think of a way to do this without a loop. I have a bunch of start and end dates. Each row is a record and I want to be a...

7 years ago | 2 answers | 0

Question

Have you seen this blog on MATLAB?

There is some serious MATLAB hate going on here. I'm not sure what they want you to abandon MATLAB for... maybe a combination of...

7 years ago | 5 answers | 1

Question

SAP OLAP Database connection

I am looking to connect to SAP BW or OLAP. They have several methods. The java SDK is not an option because of internal issues. ...

7 years ago | 0 answers | 0

Answered

finding x and y coordinates of the image and spline fit

You have to define the coordinate system then decide which points you want to use for interpolation. Why are you after an equati...

finding x and y coordinates of the image and spline fit

You have to define the coordinate system then decide which points you want to use for interpolation. Why are you after an equati...

8 years ago | 0

Answered

How do you initialize an N*M matrix?

To initialize an N-by-M matrix, use the “zeros” function. For example, create a 3-by-5 matrix of zeros: A = zeros(3,5); You ...

How do you initialize an N*M matrix?

To initialize an N-by-M matrix, use the “zeros” function. For example, create a 3-by-5 matrix of zeros: A = zeros(3,5); You ...

8 years ago | 6

| accepted

Answered

How to make a 4D graph

http://www.mathworks.com/help/matlab/ref/scatter3.html check out vary marker color

How to make a 4D graph

http://www.mathworks.com/help/matlab/ref/scatter3.html check out vary marker color

8 years ago | 1

Answered

PlotYY X axis doubled

you can turn it off by then you won't know if your xaxis consistent for each y axis. it's best to make them match turn off (n...

PlotYY X axis doubled

you can turn it off by then you won't know if your xaxis consistent for each y axis. it's best to make them match turn off (n...

8 years ago | 0

Answered

Generating random numbers from normal distribution

Yes you can do this you just need the right transformation. You cannot generate a bounded normal distribution. It needs to be de...

Generating random numbers from normal distribution

Yes you can do this you just need the right transformation. You cannot generate a bounded normal distribution. It needs to be de...

8 years ago | 1

Answered

'x10^5' show up in MATLAB plots

There is a x-axis for each y-axis so you need to change the formatting on both of them not just the current one (gca) [AX,H1...

'x10^5' show up in MATLAB plots

There is a x-axis for each y-axis so you need to change the formatting on both of them not just the current one (gca) [AX,H1...

8 years ago | 0

| accepted

Answered

Export several arrays with the same name to a xls

This will work up to the Z column in Excel (26 mat files) I don't know how many mat files you have. mat_files=1:26; %number...

Export several arrays with the same name to a xls

This will work up to the Z column in Excel (26 mat files) I don't know how many mat files you have. mat_files=1:26; %number...

8 years ago | 0

| accepted

Answered

Displaying gif Image in Matlab

[I cmap] = imread('image_name.gif','frames','all'); image(I); colormap(cmap);

Displaying gif Image in Matlab

[I cmap] = imread('image_name.gif','frames','all'); image(I); colormap(cmap);

8 years ago | 2

Answered

Experiences with release 2013a

I love the new linear regression class. Very powerful combined with datasets. It has made things much easier and cleaner for me....

Experiences with release 2013a

I love the new linear regression class. Very powerful combined with datasets. It has made things much easier and cleaner for me....

8 years ago | 1

Answered

How to rearrange the rows of a matrix so the column values loop

"If you only want them to be counter-clock wise, why not convert the [x,y] point to polar coordinate and sort them by angle?" ...

How to rearrange the rows of a matrix so the column values loop

"If you only want them to be counter-clock wise, why not convert the [x,y] point to polar coordinate and sort them by angle?" ...

8 years ago | 0

Answered

How do you connect to a remote machine in MatLAB?

if the remote machine has been configured for sharing you should be able to map a network drive and write to a folder on the rem...

How do you connect to a remote machine in MatLAB?

if the remote machine has been configured for sharing you should be able to map a network drive and write to a folder on the rem...

8 years ago | 0

| accepted

Answered

Problem with detection of multicolinearity in a matrix

would a correlation matrix help you out? RHO = corr(X)

Problem with detection of multicolinearity in a matrix

would a correlation matrix help you out? RHO = corr(X)

8 years ago | 1

Answered

Concatenating a double array and two cell arrays

does this work sitedata=horzcat(a, b, num2cell(site_Cflux))

Concatenating a double array and two cell arrays

does this work sitedata=horzcat(a, b, num2cell(site_Cflux))

8 years ago | 0

| accepted