Multivariate Regression Test Statistics

1 vue (au cours des 30 derniers jours)
Kevin Willeford
Kevin Willeford le 12 Fév 2021
Commenté : Kevin Willeford le 15 Fév 2021
I have designed a multivariate regression with two response (Y) and three predictor (X) variables using mvregress. The response variables are horizontal and vertical eye position (h, v) and the predictor variables are a constant term with horizontal and vertical gaze position (x, y). How do I compute a p-value for each of my coefficients given what the function returns?
% multivariate regression
n = numX * numY; % number of gaze positions
d = 2; % number of response variables
numCoeffs = d * 2 + d;
X0 = ones(n, 1);
X1 = XX(:);
X2 = YY(:);
X = [X0, X1, X2]
Y1 = H;
Y2 = V;
Y = [Y1, Y2];
% coefficients, covariance matrix, residuals, variance of parameters, loglikelihood value, correlation matrix
[B, S, R, V, L] = mvregress(X, Y);
predY = X * B;
C = corrcov(S);
E = sqrt(diag(V));
  4 commentaires
dpb
dpb le 13 Fév 2021
Yeah, same as for OLS, if you ran a separate OLS regression for each outcome variable you would get the same coefficients, standard errors, t- and p-values, and confidence intervals.
So, for each b,
t=b/SE;
p>|t| --> 2*(1-tcdf(t,dof))
Kevin Willeford
Kevin Willeford le 15 Fév 2021
I have two response variables, three predictor variables, and thus a total of six coefficients returned. I believe the DOF = 3 in this case because there are three predictor variables for each response variable. When I followed the above procedure, I got p values greater than 1.00 which cannot be correct?
[B, S, R, V, L] = mvregress(X, Y);
predY = X * B;
C = corrcov(S);
SE = sqrt(diag(V));
T = B(:) ./ SE;
P = 2 * (1 - tcdf(T, DOF));
B =
1.496605020258772 -0.000313029492716
0.000389624484379 -0.004938677958117
-0.053311651917679 0.000022111435119
SE =
0.011649490387665
0.000658994692039
0.000658994692039
0.000807196421197
0.000045661925054
0.000045661925054
T =
1.0e+02 *
1.284695699516166
0.005912407020668
-0.808984542087009
-0.003877984149776
-1.081574627492846
0.004842422892381
P =
0.000001039860816
0.595950373533595
1.999995836953775
1.275955907490467
1.999998257520655
0.661365573305742

Connectez-vous pour commenter.

Réponses (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by