# the cyclist

### Alden Scientific

Head of Modeling and Statistics at Alden Scientific. Obsessive runner. Professional Interests: Predictive modeling, statistics. (I don't respond to email via author page, but will usually look at a question if you send me a link to it.)

**Programming Languages:**

Python, R, MATLAB, SQL

**Spoken Languages:**

English

**Statistics**

RANK**14**

of 277.735

REPUTATION**14.701**

CONTRIBUTIONS

**43** Questions

**5.028** Answers

ANSWER ACCEPTANCE **
74.42%
**

VOTES RECEIVED**2.768**

RANK**9.830** of 18.793

REPUTATION**57**

AVERAGE RATING**0.00**

CONTRIBUTIONS**1** File

DOWNLOADS **2**

ALL TIME DOWNLOADS**576**

CONTRIBUTIONS**0 Posts**

CONTRIBUTIONS**0** Public Channels

AVERAGE RATING

CONTRIBUTIONS**0** Highlights

AVERAGE NO. OF LIKES

**Content Feed**

comparison between a string/or cell and categorical data

Your method works for me: Trading = categorical({'As is';'bla'}); B='As is'; B == Trading(1) You did have a lower-case "b"...

ongeveer 7 uur ago | 0

I can't draw the vector field

The problem is the Inf values in u and v. Removing them: [x, y] = meshgrid(-0.9:0.3:0.9, -0.9:0.3:0.9); R1 = (x.^2 + y.^2).^.5...

ongeveer 7 uur ago | 0

3D Histogram of 50x50 data

You can make this style of plot using the histogram2 function.

1 dag ago | 0

| accepted

Variables corresponding with NaN won't graph

Without seeing your code or your data, it is difficult to give specific advice. But the gist would be something like this: iden...

2 dagen ago | 1

cross-correlation of multivariate data to differnt lag numbers

Try the xcorr function.

3 dagen ago | 0

Predictor and Response Variables must have same length error

fitnlm expects column vectors as input, not row vectors. Rows are the observations, and columns are variables. y = [0 0 ...

3 dagen ago | 1

| accepted

Plotting different sized vectors

Here is one way. If you have many participants, I would generalize this a bit differently (e.g. by storing participant vectors i...

3 dagen ago | 0

| accepted

Help with principal component analysis of FTIR spectra

Frankly, I don't see why you would use PCA for this analysis. I expect there are some specialized statistical tests for determin...

3 dagen ago | 0

Retime function creates new rowtimes going back to 1899

You have a few dates from 1899 in your input data load CO2_TT.mat [minDateTime,indexToMinDatetime] = min(CO2_TT.DateTime) C...

4 dagen ago | 0

| accepted

How to create curved arrows by giving tail and head coordinates?

It looks like the circular_arrow submission in the File Exchange might do what you want. I suggest downloading that function and...

4 dagen ago | 1

| accepted

How can i find indices of constant elements between 2 arrays?

Do you mean the non-zero elements that are the same between the two arrays? A = [1 2 0; 0 1 0; 5 0 8]; B = [1 3 0; 0 4 0; 5 0 ...

4 dagen ago | 0

| accepted

how to find average curve of n curves? n=3 in this case

Here is how to get at the underlying data, from the figure file. open("fig3b_XveKu_7.9%_S_parameters_VNA_CST_S21.fig") h = f...

5 dagen ago | 0

Extracting from boxchart function the median, quartiles, and whisker data.

As you may know, but just in case you do not, there is also the boxplot function, which has more flexibility than boxchart.

5 dagen ago | 1

How can I save "alpha" and "beta" parameters as double using fitdist command?

I'm not sure what part is giving you trouble. Here is how to pull the parameter values out of the distribution object. (The full...

6 dagen ago | 0

| accepted

What does this command line mean? (matrix A =[A t])

Square brackets can be used to concatenate arrays.

11 dagen ago | 0

Send Emails from GUI

I don't know the answer to your question, but you might have better luck using the MATLAB-supplied sendmail function, rather tha...

12 dagen ago | 0

Multiply column by a number

Here is one way: varList = ["Var7","Var8","Var9"]; tbl{:,varList} = tbl{:,varList}*15;

12 dagen ago | 0

How do I extract data from a matrix with a specific column value and place into a row in a new matrix.

Here is a straightforward method, assuming equal number of duplicates in the first column. % Input M = [1, 25 3, 33 3. 45 2...

14 dagen ago | 0

How can I fill the area between these lines and curves?

You can use the fill function.

14 dagen ago | 1

Delete columns if sum of a group of 10 columns is zero

Here is one way. for nc = 123:-10:3 colIdx = nc:(nc+9); if sum(Data1(15:end,colIdx),"all")==0 Data1(:,colIdx...

15 dagen ago | 0

| accepted

two x-axes, one above and one below, inverted

This documentation explains how to do multiple axes. And then you'll need to set the XDir property of one of the axes to "rever...

16 dagen ago | 0

Fit nonlinear regression model

Answering your main question: beta0 is the initial guess at the coefficients of the fit. In your case, MATLAB is expecting a vec...

16 dagen ago | 0

| accepted

Why there is a Invalid Expresssion error in my fit function?

Your code works: n = [1433;2700;1000000]; s = [1170.98;780.65;390.33]; f= fit(n,s,'power1') Did you perhaps try to spread th...

16 dagen ago | 0

| accepted

Ordering of an array based off conditions

% Input data tmp = {'1e2','1h4','1t0', '3g2', '3g3', '3g4', '3q0', '3q1', '3q2'}; letter_list = {'t','q','e','g','h','i','j'};...

17 dagen ago | 0

| accepted

How can I set the NaN values to black in a pcolor plot?

Set the axes background color to black: % Generate sample data data = rand(10, 10); data(3, 3) = NaN; % Set a specific value...

18 dagen ago | 1

| accepted

extract statistically independent words

You can do n-gram processing with the Text Analytics Toolbox.

19 dagen ago | 0

problem inconsistent dimension arrays

We can't run your code because we don't have all the inputs to do so. I suggest using the debugger to halt your code at that lin...

19 dagen ago | 0

| accepted

In order to automate the fitlm command I need to select numerical data from a matrix, and matching variable names from another character array. I get an error on fitlm command

One way that is close to the syntax you used is this: lm=fitlm(tbl,sprintf('%s ~ %s',erase(strtrim(VarNames(OriColumns(i,1),:))...

19 dagen ago | 0

I would like to delete the black line in the boxes

Those are the whiskers, in the compact style. You can set their length to zero. (I also removed outliers, to show it more clearl...

20 dagen ago | 0

| accepted

A line does not appear when I plot

The way you have coded this, both h and Temp are going to be scalars (single values) after the loop completes, so there is only ...

21 dagen ago | 1