Questions tagged [matlab]

A programming language/environment. Use this tag for any on-topic question that (a) involves MATLAB either as a critical part of the question or expected answer, & (b) is not just about how to use MATLAB .

MATLAB is a high-level language and interactive programming environment developed by MathWorks. It is the foundation for a number of other tools related to statistical analysis, including Statistics Toolbox, Optimization Toolbox, Curve Fitting Toolbox and Neural Network Toolbox.

Some informative links that show up quite often in answers:

1293 questions
5
votes
4 answers

How to calculate the product of Gaussian variables in Matlab

I want to calculate the distribution of a product of two i.i.d. Gaussian distributed variables a and b. In principle, this should be possible by defining a new variable x with a dirac delta distribution To get the distribution over x (the product…
Edgar
  • 163
2
votes
1 answer

statistical difference between two linear regression slopes in matlab

I have the following data, which I'm analysing in matlab: d = [1901 17.5 11.5 1902 12.5 8.5 1903 12.5 11.5 1904 18.5 18.5 1905 12.5 10.5 1906 10.5 8.5 1907 19.5 16.5 1908 12.5 13.5 1909 8.5 9.5 1910 …
2
votes
1 answer

Standard error computed by MATLAB multcompare?

Here is my toy data y = [1; 1; 2; 6; 7; 3]; and their group information is as follows grp = ['a'; 'b'; 'b'; 'a'; 'c'; 'c']; I perform the one-way ANOVA on it. [~, ~, stats] = anova1(y, grp, 'off'); Then, I do a pairwise comparison with…
0
votes
1 answer

Wilcoxon Signed Rank

I have 4 matrices of size 686810 each. To understand better, we can represent each matrix as a graph of 68 nodes. For each node I compute betweeness centrality, strength, clustering coefficient, and vulnerability. So, for each parameter for example…
Lou
  • 1
0
votes
0 answers

Determining a relationship in statistical data

I have a large set of data that models the average number of days it takes for people to re-lease a house of type $i$. I have created an example via Matlab below using random data to help illustrate this. In this example, there are five different…
M B
0
votes
1 answer

One hot encoding for (40x10) images

I have 40 different images (1, ..40),( each one has 10 repetition " 40x10"),i should use one hot encoding for each image (the 40), for example image (1) the one hote encoding will be encoding will be: [ 1 0 0 0 0 0 0.....40(0)], for images 2 the one…
navin
  • 1
0
votes
1 answer

One hot encoding for images ( 40x10 images)

I have 40 different images (1, ..40),( each one has 10 repetition " 40x10"),i should use one hot encoding for each image (the 40), for example image (1) the one hote encoding will be encoding will be: [ 1 0 0 0 0 0 0.....40(0)], for images 2 the…
navin
  • 1
0
votes
1 answer

Trying to understand the mathmatics behind the matlab equations in anamolous detection in Andrew's machine learning

Basically I do not understand the mathematics behind the follow in Andrew machine learning on anomalous detection. X = bsxfun(@minus, X, mu(:)'); p = (2 * pi) ^ (- k / 2) * det(Sigma2) ^ (-0.5) * ... exp(-0.5 * sum(bsxfun(@times, X * pinv(Sigma2),…
0
votes
0 answers

simple error model for observational data in matlab

Consider that I have a matrix: r1 = rand(365,5); which represents the air temperature observed at a number (5) of stations in a country (each row is a day of year and each column is a different air temperature station). Thus, in this example I have…
0
votes
1 answer

How can I run the shell script "./segmentAndTrack.sh " in MATLAB?

I want to run the shell script "./segmentAndTrack.sh " in MATLAB. Can you tell me the procedure. I am newbie in shell script. Any kind of help welcome. My OS is linux
Leone
  • 67
  • 1
  • 1
  • 8
0
votes
1 answer

How can a constrained function in an objective function be used with fmincon in matlab?

The below given constrained function is used in the objective function that is going to be minimized by using fmincon. fun=@(x) 2*(1-x)*(0.5<=x)*(x<=1) The objective function is obj =(c(i).*x(i)+b(i).*quad(fun,l,u)) Due to the function defined in…
Dirk
  • 213
0
votes
1 answer

Power of KStest

I have a basic question , I wanna to calculate the power of one sample kstest. Please help me out . I have the sample of 76 data. Calculated the h,p,k,cv for the given sample but not able to calculate the power . thanks in advance.
0
votes
0 answers

What Matlab optimization solver gives you the t-stats and p-value for the estimates?

I calculate a data log likelihood (evaluated at a set of parameters to be estimated), and my task is to find the set of parameters that maximize my log likelihood. My problem is: thought there are a bunch of matlab optimization algorithms that can…
Ruby
  • 67
0
votes
0 answers

10 balls in 3 boxes simulation in MATLAB

Does anyone know how I could use matlab to calculate the probability of throwing 10 balls at 3 buckets? Bucket 1 has a 1/4 chance, bucket 2 has a 1/2 chance and bucket 3 has a 1/4 chance. So how would I use MATLAB to calculate the probability of…
Edward
  • 1
0
votes
1 answer

Matlab classify function for multi-class classification

What kind of Machine Learning method does the function "classify" in Matlab use for the multi-class classification? Is it SVM? If so, how does it use the classifier for multiple classes?
cerebrou
  • 275
1
2