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.

learn more… | top users | synonyms

0
votes
0answers
16 views

How to reconstruct the observed data using weighted-PCA in Matlab?

Calling pca function in Matlab using the inverse of variances as variable weights: ...
2
votes
0answers
27 views

Sandwich Estimator in Maximum Likelihood Estimation of Logit

I am estimating a discrete choice model using mixed logit using Halton Draws. So everything is basically numerically done. The code is written in MATLAB. I am using MATLAB's fminunc to do ...
1
vote
1answer
33 views

Neural Network System Identification

I am trying to implement a Neural Network to identify a Nonlinear System. I have implemented a very simple system in simulink and on the basis of examples of its input and output I would like to have ...
0
votes
0answers
11 views

Visualization of two terciary vectors

Let $x,y\in\{-1,0,1\}^n$ are two tertiary vectors of the same size where $n$ is a large integer such as $n=1000$. I want to see that $y_i=x_i$. Do you have any idea of the visualization of that ...
0
votes
0answers
7 views

How to obtain all but an indexed row in a matrix - MATLAB? [on hold]

I am estimating a Vector Autoregression with ratios and first differences. Namely, I have T/Y, G/Y and $\Delta$Y. Where T is total taxes, G is government spending and Y is GDP. To compute my Impulse ...
-1
votes
1answer
29 views

Which one is faster? MATLAB SVM or scikit SVM? [closed]

Which one is faster, SVM from MATLAB or SVM from scikitlearn?
2
votes
0answers
24 views

How to remove horizontal bar in Hindi word Matlab

I wish to remove the horizontal bar (Shirorekha) from the word to get characters from the following image, for character recognition. Any ideas as to how can I do that. I tried to use Hough ...
0
votes
0answers
18 views

Dynamic Neural Network with randomly shuffled training data

I'm using an Nonlinear AutoRegressive neural network with eXternal input (NARX) to model a water conveyance system as part of my master thesis. I'm implementing this model with MATLAB R2013b. In ...
1
vote
0answers
21 views

Matlab: Help in mitigating the problem: Non-positive definiteness of a matrix

EKUKF toolbox contains a file ut_sigmas.m I am facing a frustrating problem with the covariance matrix $P$ of the measurement when using Cholesky decomposition. ...
-1
votes
0answers
9 views

Matlab gradient and hessian computation for symbolic vector function [migrated]

I am trying to use the Matlab "gradient" and "hessian" functions to calculate the derivative of a symbolic vector function with respect to a vector. Below is an example using the sigmoid function ...
0
votes
0answers
28 views

Nan values in regression MATLAB

I run the following regression: mdl=fitlm(Reg_var(1:end,2:end),Reg_var(1:end,1),'RobustOpts','on') My output: ...
0
votes
0answers
18 views

advice regarding which ant clustering algorithm to choose

I am working on this project in which I am going to take a small corpora of input text consisting of works of literature from different genre. After extracting a set of features, I wish to perform ...
1
vote
1answer
132 views

Why are all my p-values so low in logistic regression model?

I'm trying to make a regression model to explain a dependent variable that follows a binomial distribution - I have data on the number of successes and the number of trials for each observation. The ...
0
votes
1answer
22 views

Validation of Kernel Regression

I have a data set which I divided in two part(development and validation). I am using kernel regression for build a relationship between independent and dependent variables in development period data. ...
6
votes
1answer
51 views

Computing Dvoretzky–Kiefer–Wolfowitz bounds in MATLAB

When I run the Kolmogorov-Smirnov test (kstest2 function in MATLAB) on two given data vectors, I get the value of KS Statistic. How should I compute Dvoretzky–Kiefer–Wolfowitz (DKW) bound using this ...
1
vote
0answers
14 views

Matlab FACTORAN error on line 162: a covariance matrix is not positive definite [closed]

I have a data set called Z2 that consists of 717 observations (rows) which are described by 33 variables (columns). The data is standardized by using ZSCORES. Additionally, there is no case for which ...
0
votes
0answers
48 views

Trained Logistic Regression returns 'NAN' for some out of sample data

I'm using MATLAB R2015a, glmfit function for training and glmval for out of sample ...
0
votes
0answers
29 views

dose kernel trick map 2d data to 3d data really?

I want to learn something about kernel trick in svm so I use this code: ...
0
votes
0answers
36 views

Johansen test results using James LeSage toolbox

I am a little new to econometrics. Please pardon me for this silly question. I was running a Johansen cointegration test on two time series using the econometrics toolbox provided by James LeSage for ...
1
vote
1answer
42 views

Confusion Matrix Matlab has a 0% for a class during training

When I train Multi-Layered Perceptron using Matlab for 6 classes, for one of the classes I get a 0% in GREEN in the confusion matrix. This leads to to a high error percent for the overall training, ...
3
votes
1answer
79 views

R or MATLAB - how to fit a function to experimental data, satisfying specific constraints

My first question here, hope it works :) I have experimental data $(x_i,y_i),i=1\ldots n$, $n=O(10)$, which describe a function $y=f(x)+\epsilon$ defined in $I=[0,1]$. $y_i$ is a ratio between ...
0
votes
0answers
30 views

Cross-Validation gives different result on the same data

I have done Cross-Validation by crossval function in matlab on my data, but when I run the Cross-Validation many times, it give me a different results, so is that ...
0
votes
1answer
43 views

Singular Value decomposition positive components

I am using Singular Value Decomposition (SVD) applied to Singular Spectrum Analysis (SSA) of a timeseries. ...
0
votes
0answers
13 views

How to use the bootstat function to bootstrp without replacement? [migrated]

I have a simple MATLAB code to perform a bootstrap, but I need to do this without replacement. How do I write the bootstat function such that there is NO ...
7
votes
0answers
156 views

Biased estimator for regression achieving better results than unbiased one in Error In Variables Model

I am working on some syntatic data for Error In Variable model for some research. Currently I have a single independent variable, and I am assuming I know the variance for the true value of the ...
2
votes
1answer
54 views

Percentage of contribution of multiple factors to a single dependent variable

I have a set of data (underway observation along cruise track) which includes one dependent variable A and three independent variables B, C, and D. It's known that A is related with each of the three ...
-1
votes
0answers
14 views

subtraction mean from nonstationary time series [closed]

suppose we have non stationary time series,with size size(B) ans = 2000 1 i selected several parts from this time series and create 4 new ...
0
votes
1answer
28 views

Do the values in the second factor from a principal component analysis have to have different signs?

I am computing the principle component matrix of a financial database and to obtain the second factor I extrapolate the second vector. So far, it's easy, but I wonder, do the signs of the second ...
0
votes
0answers
13 views

Evaluate the multivariate normal using variance matrices $\boldsymbol{\Lambda}+\alpha_{i}\mathbf{a}\mathbf{a}^{T}+\beta_{j}\mathbf{b}\mathbf{b}^{T}$

I need to calculate a huge amount of inverses and determinants to evaluate the pdf of the multivariate Gaussian. Specifically I need to compute the inverses and determinants of the following ...
1
vote
1answer
18 views

Matlab - why crossval function inputs a full trained model?

The question is regarding the Matlab implementation. As we can see here, the crossval function expects to receive a full trained model. For example, my data ...
2
votes
0answers
24 views

Difficulties in interpreting the Equations in Parameter estimation for linear dynamical system

I have implemented the Kalman Smoothing with Expectation Maximization based on the Paper Parameter Estimation for Linear dynamical system. All notations are based on this paper. The model is an IIR ...
0
votes
0answers
45 views

using Cross Validation in matlab with neural networks

I want to make a cross validation on neural network, I tried to pass the labels to crossval function, with the help of ...
0
votes
0answers
30 views

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 ...
0
votes
0answers
37 views

autoregressive coefficient and white noise

I have one variable of Monthly rainfall data. I have developed a forecasting model using Back-propagation Neural Network Model (using Matlab), with 3 input units and one output unit, the three inputs ...
1
vote
0answers
30 views

Parameter selection in one class svm

Is there any accepted way to select the best parameters for one-class svm with a linear kernel in r? I have managed to run the svm function in e1071 but it is super sensitive to the model ...
1
vote
0answers
19 views

On the computational efficiency of some matlab code when finding the loglikelyhood

I am looking at some code on GAS models found here (number 7). The code finds the log-likelihood of the joint conditional distribution of each observation by summing up the single log-likelihood of ...
1
vote
1answer
29 views

Clarification in the terms of log-likelihood expression

I am trying to implement Eq(7) given below from Parameter estimation for Linear dynamical system where Q is a 2 by 2 covariance matrix of the process noise. The model is ...
0
votes
1answer
63 views

Maximum a posteriori estimation with one single training example?

I am doing maximum a posteriori (MAP) to estimate $\mu$ and $\sigma$ with $N$ samples drawn from $\mathcal{N}(5, 1)$. The priors that I place are $\mu\sim\mathcal{N}(5, 1)$ and ...
0
votes
0answers
38 views

The accuracy measure of a classification process

I have build the signal processing and feature extraction models, those features, inputed to Neural Network using matlab, which is give me the following performance measure,And I have several ...
0
votes
0answers
41 views

Are there ways to improve Levenberg-Marquardt backpropogation performance in Neural Networks?

When using Levenberg-Marquardt optimization for a function approximation problem, the performance and speed generally trumps that of the gradient descent. I am approximating the functions cos(n * Pi) ...
1
vote
0answers
28 views

Confidence interval for variances

I have a lot of variances $\sigma^2(x)$ as these: Now I have two task: remove the vertical outliers and compute the confidence intervals (for all cases, this is only one case). I think that their ...
0
votes
0answers
22 views

How is a most probable Hessian used to calculate Bayesian Prediction Intervals?

I'm using the MATLAB Neural Network Toolbox to use Bayesian Regularization (trainbr.m) to train a neural network which has one input, one hidden, and one output layer. I use this network for ...
0
votes
0answers
36 views

Matlab survival curve log rank test

I am trying to do survival analysis in matlab and want to calculate log rank test scores among several curves. I found a possible code to do log rank here. But based on its description, it can only do ...
3
votes
1answer
44 views

Overall $p$-value for a multiple linear regression (in MATLAB)?

I wish to explore the effects of the component percentages (independent variables) on fruit sweetness $S$ (dependent variable). Assume for simplicity that our fruit only contains 3 components, ...
0
votes
0answers
25 views

Output's probabilities of ANFIS in MATLAB

Is anyway to have output probabilities of binary classification using MATLAB ANFIS toolbox (or other related toolboxes)? Outputs are 1 and 0. So if we have 0.7 for ...
0
votes
0answers
60 views

Generate complex random vectors distributed as $\textit{proper}$ Complex Gaussian

This is different from this and this question. How can we generate (in Matlab) complex random vectors which are distributed according to the proper complex distribution $\mathcal{CN}(\vec\mu, ...
2
votes
0answers
28 views

Mahalanobis Distance - Geometric Place

Given a matrix $\mathbb{X}$ of 20 elements, representing 20 observation of a 5-variable normal, I was asked to find the Sample Mean Vector and Sample variance matrix and to find the geometric place of ...
0
votes
0answers
42 views

How to use minor component analysis to forecast time series?

I would like to forecast a time series based on minor eigenvalues of the autocorrelation matrix. But I seem to be doing something wrong. I have the following steps implemented in MATLAB, but the ...
0
votes
2answers
47 views

Computationally efficient Gaussian MAP estimation algorithm in MATLAB

I have a MAP estimation model for a Gaussian prior and i.i.d Gaussian noise: $$y=x+n$$ where $x\sim\mathcal{N}(0,\Sigma)$ and $n\sim \mathcal{N}(0,\sigma^2I)$. The MAP estimate is given by $$ ...
1
vote
1answer
90 views

Robust OLS standard errors (Newey-West)

I am running a simple OLS regression with HAC adjustment (i.e. Heteroschedasticity and Autocorrelation adjustment) using the following function in hac() in matlab. ...