Tag Info

New answers tagged

0

Your first interpretation is correct, the expected value of the dependent value conditional on the third quarter (and on the remaining regressor variables) is defined as you did. Given a significance level $\alpha=0.05$, all the variables except the second quarter are individually significant since the p-values related to the $t$-test statistics are lower ...


0

As a complement to the answer given by @MichaelHardy, substituting $Y = M\beta + \varepsilon$ (i.e., the regression model) in the expression of the least squares estimator may be helpful to see why the OLS estimator is normally distributed. $$ \begin{eqnarray} \begin{array}{l} \hat\beta &=& (M^\top M)^{-1}M^\top \underbrace{Y}_{Y = M\beta + ...


0

With dummy variables, everything is relative to the omitted group. So lets say in the first regression, you included all categories of 1-24, if none are significant, it suggests that you cannot tell the difference between those values and the value for the 25th category. This could, for example, be a function of the implied coefficient for the 25th category ...


0

The Gamma distribution is commonly used. Your plot does look like it might have a sharper peak than that, in which case you might use an inverse Gaussian distribution. Both these distributions have two parameters so you'd need to fit them to your data using Maximum Likelihood Estimation. The equations for these are given in the Wikipedia pages.


0

Regression problems for one explained variable of one independent variable are generally of the form $$f(x,y;a,b,c\cdots)\approx0$$where you want to find the "best" values of the unknown parameters $a,b,c\cdots$ for a given data set $(x_i,y_i)$. The common procedure is to minimize the global quadratic error, computed as ...


0

Hint If you turn the problem into an optimization problem, Occupy Gezi gave the solution and this could be the simplest. Another way would be to set $x=y z + \lambda^2$ and to run the regression using $\lambda,y,z$ as tuning parameters.


0

They run OLS regressions; it would be odd if the axis intercept ($c$) would happen to be $0$ for all variables. But as they are focussing on to autogregressions of the variable vector, I suppose, they simply do not consider the intercept interesting enough to put it in the estimation results. I agree that it is somewhat unconventional that they give ...


1

As Occupy commented, using weighted least squares is the solution. Let me take something similar from data validation and data reconciliation. In this area, what we want to minimize is $$\Phi=\sum_{i=1}^n \Big(\frac{y_i^*-y_i}{\sigma_i}\Big)^2$$ where $y_i^*$, $y_i$ and $\sigma_i$ are respectively the reconciled value, the measured value and the standard ...


0

EDIT: Assuming $s > 0$ and $B$ is positive definite, take any nonzero vector $v$, let $t = v' B^{-1} v$ and let $A = (s/t)^{1/2} v$.


1

for what it is worth, the least squares solution to $$ H \hat{x} = z $$ is considered by multiplying on the left by $H^t,$ giving $$ H^t H \hat{x} = H^t z. $$ The matrix $H^t H$ is square and symmetric, indeed positive semidefinite. It is called the Gramian of the system in applications. If the Gramian is nonsingular, therefore invertible, there is a ...


1

Suppose that $\exists y \in Ker(A) / y \neq 0$. Now, let $\hat{x}$ be a least squares solution. That is: $\hat{x}$ is such that $||A\hat{x} - b||_2 = min_{x \in V} ||Ax - b||_2$. Notice that $A(\hat{x} + y) = A\hat{x} + Ay = A \hat{x}$, hence $||A\hat{x} - b||_2 = ||A(\hat{x} + y) - b||_2$. This means that you have just created another solution that also ...


1

Your least squares solution is minimizing $\hat x^T A \hat x$ If $A$ does not have full rank, there is some vector $y$ such that $Ay=0$. Then $(\hat x+y)^TA(\hat x+y)=\hat x^T A \hat x$ so you can add any multiple of $y$ to your solution and get the same product.


0

Let $e$ be the estimated errors. I'll focus on a simple linear regression $cov(x,e) = cov(x,y-a-xb) = cov(x,y-(\bar{y}-\bar{x}b)-x\frac{cov(x,y)}{var(x)})=cov(x,(y-\bar{y})-(x-\bar{x})\frac{cov(x,y)}{var(x)}) $ $= cov(x,y)-cov(x,(x-\bar{x})\frac{cov(x,y)}{var(x)}) = cov(x,y)-\frac{cov(x,y)}{var(x)}cov(x,(x-\bar{x})) = ...


1

Here's my guess. Well suppose you have N data points. If you fit a polynomial of order M, then you essentially have N equations with M unknowns. If $M>N$ then you have more unknowns than equations. This is definitely not advisable (the regression requirements are not satisfied). If $M=N$, you have M equations and N unknowns and would get a perfect fit. ...


0

Fitting of $$y=A(1-2e^{bx})$$ to a set of data $(x_1,y_1),(x_2,y_2), ... , (x_k,y_k), ... , (x_n,y_n)$ I agree with the method proposed by Claude Lebovici. Another approach consists in : Ranking the data in increassing order of $x_k$ Let $S_1=0$. Then, from $k=2$ to $n$ , compute $S_k=S_{k-1}+\frac{1}{2}(y_k+y_{k-1})(x_k-x_{k-1})$ Compute $b$ from : $$ ...


0

The model $$y = a\,(1-2e^{bx})$$ is nonlinear with respect to its parameters $a,b$ and nonlinear regression should be used. The problem is that you need to start with rather good estimates and that, as already said in comments, you cannot linearize the model. So, how to get estimates ? First approach Suppose that you fix $b$ at a given value. Then define ...


1

The problem is intrinsically nonlinear since you want to minimize $$SSQ(a,b,c)=\sum_{i=1}^N\big(ae^{bt_i}+c-y_i\big)^2$$ and the nonlinear regression will require good (or at least reasonable and consistent) estimates for the three parameters. But, suppose that you assign a value to $b$; then defining $z_i=e^{bt_i}$ the problem turns to be linear $(y=az+c)$ ...


4

A direct method of fitting (no guessed initial values required, no iterative process) is shown below. For the theory, see the paper (pp.16-17) : https://fr.scribd.com/doc/14674814/Regressions-et-equations-integrales


0

So your $\beta= \dfrac{\sum(y_i-\bar y)x_i}{\sum(x_i-\bar x)x_i} =\dfrac{\sum(y_i-\bar y)(x_i-\bar x)}{\sum(x_i-\bar x)^2}$ Since $\sum(y_i-\bar y)\bar x=0$ and $\sum(x_i-\bar x)\bar x=0$. EDIT: $\sum(y_i-\bar y)\bar x= \bar x\sum(y_i- \bar y)\\=\bar x[\sum y_i-\sum \bar y]\\=\bar x[n\bar y-n\bar y]=0 $


1

The rule that you are talking about is known and it is called 3-$\sigma$ rejection rule. This is the simplest way of robustifying the regression model. You can find anything you are searching for here.


0

The sum of the components of $l(x_0)$ can be expressed as $l(x_0) \mathbf{1}_{n}$. After defining $S_k := \sum_{i=1}^n x_i^k$ we can rewrite the sum as follows \begin{align*} l(x_0) \mathbf{1}_{n} &= b(x_0)^T (X^TX)^{-1} X^T \mathbf{1}_{n} \\ &= b(x_0)^T (X^TX)^{-1} (S_0, \dots, S_k)^T \\ &= b(x_0)^T \begin{pmatrix} S_0 ...


2

Let $n$ be the sample size and $q$ be the number of parameters. The multiple regression equation in matrix form is $$Y=X\beta+\epsilon$$ where $Y$ and $\epsilon$ are $n\times 1$ vactors; $X$ is a $n\times q$ matrix; $\beta$ is a $q\times 1$ vector of parameters. The model is usually written in vector form as $$Y_i=X_i'\beta+\epsilon_i$$


0

Let's see if some cleaner notation can capture the gist of it. Define: $$ J=\begin{bmatrix} y_1\\ y_2\\ \vdots \\ y_n\\ \end{bmatrix},\space J=\begin{bmatrix} 1\\ 1\\ \vdots \\ 1\\ \end{bmatrix},\space X=\begin{bmatrix} x_1-\bar{x}\\ x_2-\bar{x}\\ \vdots \\ x_n-\bar{x}\\ \end{bmatrix} $$ Please note the ...


0

If you are trying to learn original hyper-parameters that e.g. make your new hyper-parameters positive (e.g. through exponential applied to the given original hyper-parameters, where the original can be positive or negative), then the only thing you need to do is compute the new gradient/Hessian/whatever derivatives you want with respect to the original ...


0

(Typically in linear regression we condition on $x_i$ and only regard $Y_i$ as random, so in what follows we treat each $x_i$ as constant.) For this problem it's important to remember that $\text{Cov}(Y_i, Y_j) = 0$ whenever $i \neq j$, otherwise $\text{Cov}(Y_i, Y_i) = \text{Var}(Y_i) = 1$. Also recall that covariance is a linear operation, so for random ...


1

The regression line is by definition the line $\hat y = ax + b$ that minimizes the SSE. On the other hand, the SST is the SSE resulting from the line $y = \bar y$. By this definition, we see that we must always have SSE $\leq$ SST.


0

Off hand I wouldn't use the normal approximation to the t-distribution unless the number of degrees of freedom is perhaps $100$ or more, but I may change my mind about that after some further thought. This notion of using $\ge30$ probably comes from confusion of this with a quite different rough rule of thumb: the sum of i.i.d. random variables is ...


1

As said in previous answers, the problem depends on what is measured. Suppose that $x$ is with no error and $y$ is measured with some error. So, the vertical distance is the good choice. For sure the problem can be different : suppose that for a know value of $x$ you measure $y$ (with some error) and also $z$ (with some error too) and, for any reason, you ...


0

Remember that regression are used for modelling, and thus it should not be reduced to a question of geometry. given $x$, we wanna give a guess "$f(x)$" of what $Y$ will be. In our case our guess will be of the form $f(x)=ax+b$. If we have observations $(x_1,y_1),\ldots,(x_n,y_n)$, we wanna measure how well our guess $ax+b$ fitted the data. A natural ...


1

The $x$-variable may be in kilograms and the $y$-variable in dollars. If you change kilograms to grams or to metric tons, or change dollars to cents, then the lines that were perpendicular in the plane before, no longer are. No such problem afflicts conventional least-squares. And suppose you classify people according to occupation (any of six types of ...


1

The reason for using vertical distance is that often you have a knob you turn that controls the important parameter of the experiment and then you measure the output. We believe you can set this parameter exactly (or so close that any error of the point is all in the measurement of the $y$ value, not the $x$ value). This is appropriate as long as the error ...


1

To use the "nearest point on the line" involves drawing a perpendicular from the point to the line. It is more complicated than the expression in the OP. There is a good reason apart from simplicity to use the vertical distance. In many circumstances, the data points are not just arbitrary scattered points in the plane. The x-coordinate represents known ...


1

A non-standard approach: Take all points in turn and estimate $\alpha=-\frac{2\tanh^{-1}(y)}x$. Then take the median $\alpha$. In case of outliers, you can even try all $\alpha$ and choose the one that minimizes some error criterion such as the Sum of Absolute Differences. (Unfortunately, this is an $O(n^2)$ procedure.)


0

Hoping I properly understand the problem, you have $n$ data points $(x_i,y_i)$ for which you want to adjust the model $$y=\dfrac{1-e^{-\alpha x}}{1+e^{-\alpha x}}$$ As already said, this is relevant from nonlinear regression and, as usual, the problem is to obtain a good starting point. So, in a first step, extract $e^{-\alpha x}$ from the expression; this ...


0

Non-linear least squares. Look into the nls function. https://stat.ethz.ch/R-manual/R-devel/library/stats/html/nls.html. So, something like: nls(y ~ (1-exp(-p1*x))/(1+exp(-p1*x)) , start=list(p1=p1_start)...)


0

Define $z=\exp (-\alpha x)$, then $y=\frac {1-z}{1+z}$ You can solve this for $z$ by the usual algebra, then take the log and divide by $-x$ to get $\alpha$


0

We have $X\in \mathbb{R}^{m\times n}$ and more equations than variables, thus $m > n$. We want to know when $$ X^t X \in \mathbb{R}^{n \times n} $$ is invertible. One critera is that $\ker X^t X = \{ 0 \}$. This means $$ 0 = X^t X u = \sum_j (X^t X)_{.j} u_j $$ only holds for $u = 0$, in other words the columns of $X^t X$ are linear independent. $$ 0 ...


0

It looks like your first fit is trying to fit all the data to a single spectral line. The problem is the bumps in your data around $6.5$ and $15$. Depending on how you assess the probable error on each point, those bumps are going to pull your fit very hard. This is especially true if you take the error to be something like the square root of the expected ...


0

What do you mean, symmetric? If you want half of the companies in your sample to have a negative "trend number" and half a positive, then compute the median revenue percentage increase over the last 5 years over all companies, and subtract this from every company's revenue increase percentage. Every company above the median increase will then have a positive ...


1

For something like a $t$-test, it is not always all that crucial that the data distributions are normal because the true assumption is that the estimators for the two sample means are normal, which will be approximately true if you have enough data points and the true data distributions aren't too crazy (this is the central limit theorem). Similarly, for a ...


0

So here is my understanding of what you have in mind. Let $X_i$ ($i=1...N$) represent the total number of units for nutrient $i$. Each nutrient has a weight $w_i$. Therefore, your objective function is $\sum_{i=1}^N w_iX_i$. But, you don't choose nutrients directly, you choose foods. Let food be represented by the subscript $j$, $j=1...J$, Each food $j$ ...



Top 50 recent answers are included