text
stringlengths
81
47k
source
stringlengths
59
147
Question: <p>I created a model for predicting a scalar variable from a set of features. I trained a linear regression on a training set, and used the resulting coefficients to produce predictions for a test set.</p> <p>Then, I did simple linear regression to the predictions as a function of the ground truth values of ...
https://stats.stackexchange.com/questions/324376/linear-regression-on-the-results-of-linear-regression
Question: <p>In this <a href="https://stats.stackexchange.com/questions/86720/log-linear-regression-vs-logistic-regression">post</a>, OP asked the difference between log linear regression and logistic regression. Two answers in the post are very clear and directly address OP's question. </p> <p>I understand log-linear...
https://stats.stackexchange.com/questions/261946/log-linear-regression-vs-poisson-regression
Question: <p>Is there any difference between <strong>Univariate Linear Regression</strong> and <strong>Simple Linear Regression</strong>? If so, what is the difference exactly? It seems both of them are exactly same. I would appreciate if anyone could cite a scientific paper that defines Univariate Linear Regression.</...
https://stats.stackexchange.com/questions/351325/difference-between-univariate-linear-regression-and-simple-linear-regression
Question: <p>Is it okay if my outcome for time series linear regression and linear regression is the same?</p> <p>I have time series data with 756 observations and for each year there are 252 observations. The time series data is from 2015-2021. It is an individual data type.</p> <p>All my independent variables are cat...
https://stats.stackexchange.com/questions/619730/time-series-linear-regression-vs-linear-regression
Question: <p><strong>1st question,</strong></p> <p>I recently learnt bayesian linear regression, but I'm confused that in what situation we should use bayesian linear regression, and when to use standard linear regression? What is the advantage of bayesian linear regression over standard one?</p> <hr> <p><strong>2nd...
https://stats.stackexchange.com/questions/393313/compare-bayesian-linear-regression-vs-standard-linear-regression
Question: <p>I created a dummy dataset and compared the performance of SKLearn LinearRegression and Keras. Why is Keras producing horrible results compared to Linear Regression?</p> <p>Code:</p> <pre><code># Create Dataset from sklearn.datasets import make_regression X, y = make_regression(n_samples=5000, n_features=10...
https://stats.stackexchange.com/questions/563448/linear-regression-vs-keras
Question: <p>I'm studying about Linear Regression and searching about it I found an example that was a graphics that the axis X was the Year and the axis Y was Price, but my doubt is: When we are talking about Year we need to treat that as a Time Series problem, yes? Also, Linear Regression applies just when the variab...
https://stats.stackexchange.com/questions/507053/linear-regression-doubt
Question: <p>Can I claim that linear regression and linear modeling are the same topics? If not, what is the difference?</p> Answer: <p>Comment made into an answer per suggestion of gung.</p> <p>Linear modeling can have meanings, outside Statistics, well beyond the Wikipedia entry <a href="https://en.wikipedia.org/wi...
https://stats.stackexchange.com/questions/126165/linear-regression-vs-linear-modeling
Question: <p>I try to do a linear regression of 84 patients, 1 numeric variable =threshold, 1 nominal variable=Group for prediction of the target numeric variable = dist.</p> <p>On the multivariate linear regression: threshold is statistical significant, and group isn't. However, when I split the data for the 2 differ...
https://stats.stackexchange.com/questions/357540/linear-regression-in-groups-multivariate-regression
Question: <p>If we want to do multiple individual (componentwise) regression, (like the one used in <a href="https://fan.princeton.edu/papers/06/SIS.pdf" rel="nofollow noreferrer">Sure-Independent-Screening</a>, Fan &amp; Lv 2007) we have that:</p> <p><span class="math-container">$$\hat\beta_{ind} = \frac{1}{n}X^Ty$$</...
https://stats.stackexchange.com/questions/523851/linear-regression-vs-individual-linear-regression
Question: <p>If I have a single model say y = ax^2 + bx + c, can I use 3 linear regression algorithms y=ax^2, y=ax and y=a to learn the original function if use the same data set. Please help me out here.</p> Answer:
https://stats.stackexchange.com/questions/661411/linear-regression
Question: <p>I am new to the field of machine learning and am just learning linear regression, and I have some questions about this concept:</p> <p>Does linear regression allow vector-valued target variables?</p> <p>Does linear regression not assume that the features are uncorrelated?</p> Answer: <blockquote> <p>Does ...
https://stats.stackexchange.com/questions/577915/linear-regression-questions
Question: <p>In explaining simple linear regression, isn't it a bit misleading for many examples to illustrate a straight line going through some scatterplot? This seems to suggest that linear regression only works if your independent and dependent variables have some sort of straight-line relationship, whereas the "li...
https://stats.stackexchange.com/questions/59782/linear-regression-explanations
Question: <p>Suppose we have a multiple linear regression model with two predictors, <span class="math-container">$X_1$</span> and <span class="math-container">$X_2$</span>: <span class="math-container">$$Y = \beta_0 + \beta_1X_1 + \beta_2X_2 + \epsilon.$$</span></p> <p>We can interpret <span class="math-container">$\b...
https://stats.stackexchange.com/questions/579066/simple-linear-regression-vs-multiple-linear-regression-interpretation
Question: <p>I am currently in a linear regression class, but I can't shake the feeling that what I am learning is no longer relevant in either modern statistics or machine learning. Why is so much time spent on doing inference on simple or multiple linear regression when so many interesting datasets these days frequen...
https://stats.stackexchange.com/questions/305116/is-linear-regression-obsolete
Question: <p>I am reading about 'interaction effects on linear regression' <a href="https://jp.mathworks.com/help/stats/linear-regression-with-interaction-effects.html?lang=en" rel="nofollow noreferrer">here</a> and came across 'stepwise linear regression'. </p> <p>There are originally 5 predictors in the model. This ...
https://stats.stackexchange.com/questions/317625/what-is-stepwise-linear-regression
Question: <p>I performed both a linear and log-linear regression to predict the price of a smartphone based on its characteristics. Now I have a question concerning the coefficients between the two models.</p> <p>In the linear regression model, the dummy variable GPS included or not is 37,7. This means that smartphone...
https://stats.stackexchange.com/questions/221910/coefficients-linear-and-log-linear-regression-model
Question: <p>It is my understanding that linear regression models and linear mixed effect regression models will produce the same regression coefficients (i.e., fixed effects); however, linear regression models produce downwardly biased standard errors leading to inflated Type I error (Cohen, Cohen, Aiken, &amp; West, ...
https://stats.stackexchange.com/questions/161703/linear-regression-vs-linear-mixed-effect-model-coefficients
Question: <p>Let <span class="math-container">$p$</span> be a positive integer and suppose that each observation in my data set is a length-<span class="math-container">$p$</span> multivariate normal vector, and I have <span class="math-container">$n$</span> (an integer) observations of the length-<span class="math-co...
https://stats.stackexchange.com/questions/612513/multidimensional-linear-regression-not-multiple-linear-regression
Question: <p>I am doing a multiple linear regression analysis project, and my instructor told me that I shouldn't be fitting the simple linear regressions at all. Does that mean scatter plots and added variable plots and diagnostic plots do not matter for individual predictors? I know that I probably don't need to tran...
https://stats.stackexchange.com/questions/266596/simple-linear-regression-in-multiple-linear-regression-analysis
Question: <p>Suppose I have a blackbox function that solves simple linear regression. Can I use this function to solve "multiple" linear regression? The blackbox computes the slope and intercept in a simple linear regression model.</p> Answer:
https://stats.stackexchange.com/questions/195199/can-we-solve-multiple-linear-regression-using-simple-linear-regression-solver
Question: <p>I have a question that I find really confusing regarding linear modelling and linear regression. I have expectation regarding the way some dependent variable (DV) are going to evolve with an independent variable (IV).</p> <p>In order to check for a relationship between IV and DV, on several participants, ...
https://stats.stackexchange.com/questions/129063/linear-model-vs-linear-regression
Question: <p>I am building a hierarchical linear model with varying intercepts. It takes the form for each unit $i$ in group $j$:</p> <p>$$y_{ij} = \alpha_j + \beta_1 x_{ij,1} + \beta_2 x_{ij,2} \quad (1) $$</p> <p>I am developing this hierarchical linear model using a complete Bayesian Analysis using stan. In stan, ...
https://stats.stackexchange.com/questions/337235/hierarchical-linear-regression-should-always-outperform-ordinary-linear-regressi
Question: <p>We can kernelize Ridge regression as shown in these notes: <a href="https://www.ics.uci.edu/~welling/classnotes/papers_class/Kernel-Ridge.pdf" rel="nofollow noreferrer">https://www.ics.uci.edu/~welling/classnotes/papers_class/Kernel-Ridge.pdf</a>. </p> <p>However would it be possible to find a vector <spa...
https://stats.stackexchange.com/questions/388403/kernelize-linear-regression
Question: <p>I have a set of 2 dimensional points [x,y], with a barycenter in 0,0 and I'm rotating it.</p> <p>I'm wondering why the linear regression of this set of points is not rotating of the same amplitude.</p> <p>Below is a sample python code :</p> <pre><code>#creating a vector with a barycenter in 0,0 vecta=my...
https://stats.stackexchange.com/questions/193723/linear-regression-after-rotation
Question: <p>For datasets of higher dimensions, how do I decide if a Linear model is sufficient to fit the data or if I have to use non linear models like regression trees to fit the data ? </p> <p>NOTE:I did try both linear and non linear models to fit the data and observed that the mean squared error is substantivel...
https://stats.stackexchange.com/questions/175103/non-linear-regression-regression-trees
Question: <p>I am studying linear regression. I want to ask is the linear word in multiple linear regression refers to the linear relationship between the target variable and each of the regression coefficients b_0, b_1,b_2, ..., b_n? Also in multiple linear regression there is a linearity assumption does this assumpti...
https://stats.stackexchange.com/questions/621226/what-does-linear-word-in-multiple-linear-regression-and-linearity-assumption-i
Question: <p>I have 11 variables (with 4 of them being sociodemographics) that predict my dependent variable. I want to perform linear regression analysis and I have two options. One: Exclude sociodemographics variables from regression analysis and just describe the participant's socidempgraphics in results and run sim...
https://stats.stackexchange.com/questions/453277/best-linear-regression-strategy
Question: <p>I'm currently reading Maths and Stats for Web Analytics and Conversion Optimisation by Himanshu Sharma and noticed the following regarding regression analysis:</p> <p>"If there is no or weak linear relationship between two variables or in other words the correlation between the two variables is zero or we...
https://stats.stackexchange.com/questions/295550/linear-and-non-linear-regression-analysis
Question: <p>If we have classical linear regression model, and one of the regressors is time series (e.g. GDP), is it necessary for that variable to be stationary? Well i do not think so, because diversity in values yields to better results when we talk about linear regression, but I encounter different opinions.</p> ...
https://stats.stackexchange.com/questions/319604/linear-regression-independent-variable-stationarity
Question: <p>I have some time series data for prices that I'm trying to perform linear regression on. However, I feel that what I'm doing is incorrect and was hoping someone could point me in the right direction.</p> <p><em><strong>Background</strong></em></p> <p>The overall background of what I'm doing is taking sen...
https://stats.stackexchange.com/questions/401771/time-series-w-linear-regression
Question: <p>Very simple. I am looking for a package that does Multivariate Linear Regression with weights on the observations. Does anyone know of a package that does this? I am shocked that I have not been able to find any.</p> <p><strong>NOTE:</strong> R does <em>NOT</em> do multivariate regression. The <code>...
https://stats.stackexchange.com/questions/52363/multivariate-weighted-linear-regression
Question: <p>Which of the following is NOT a linear regression model?</p> <pre><code>A. y = w_0 + w_1 * x B. y = w_0 + w_1 * (x^2) C. y = w_0 + w_1 * log(x) D. y = w_0 * w_1 + log(w_1) * x </code></pre> Answer: <p>When we say "linear regression" we mean linearity in <em>parameters</em>, not <em>variables</em>. The...
https://stats.stackexchange.com/questions/185851/linear-regression-model
Question: <p>I was recently in an interview and the guy asked me what is the assumptions behind the linear regression, where I mentioned that linear regression assumes a linear relationship between X and Y. The interviewer then gave me the equation:</p> <p>y=alpha1+alpha2∗x+alpha3∗x^2</p> <p>I said this isn't linear si...
https://stats.stackexchange.com/questions/662056/understanding-the-assumptions-of-linear-regression-confused-about-linearity
Question: <p>In a linear regression with several variables, a variable has a positive regression coefficient if and only if its correlation with the response is positive. ¿(TRUE OR FALSE)?</p> Answer: <p>False - if theres enough positive correlation within the independent variables ($cor(X_i,X_j) &gt; 0$), and they're...
https://stats.stackexchange.com/questions/268464/linear-regression-correlation
Question: <p>Basically in a research project I am looking at the linear regression between my independent variable: Government Stringency Index, and dependent real GDP growth.</p> <p>One area I investigate assumes if real GDP growth is more precisely measured, switching my variables in linear regression; to x on y line...
https://stats.stackexchange.com/questions/505423/x-on-y-linear-regression
Question: <p>Can anyone provide a clear list of differences between log-linear regression and logistic regression? I understand the former is a simple linear regression model but I am not clear on when each should be used.</p> Answer: <p>The name is a bit of a misnomer. Log-linear models were traditionally used for t...
https://stats.stackexchange.com/questions/86720/log-linear-regression-vs-logistic-regression
Question: <p>I have a dependent variable followed by 3 independent variables that I am trying to fit the best model for (using R). Examples of my models are below:</p> <pre><code>#Multiple linear regression mod &lt;- lm(y ~ x1 + x2 + x3, data = data) #Simple linear regression mod2 &lt;- lm(y ~ x1, data = data) mod3 &l...
https://stats.stackexchange.com/questions/562126/discrepancy-between-multiple-linear-regression-simple-linear-regression-result
Question: <p>I was reading about linear regressions on wikipedia and came across the <a href="https://en.wikipedia.org/wiki/Mean_and_predicted_response#Predicted_response" rel="nofollow noreferrer">mean and predicted response</a>. I just wanted to clarify somethings. So suppose we have a simple linear regression model,...
https://stats.stackexchange.com/questions/422076/interpretation-of-linear-regression
Question: <p>I'm using one explanatory variable in a regression tree and in a linear regression. The tree finds a split (with variance reduction splitting rule), though R2 is pretty small (0.2). On the validation data the model is confirmed. On the other hand the linear regression shows no relation (not even with 2nd o...
https://stats.stackexchange.com/questions/408857/regression-tree-vs-linear-regression
Question: <p>Is there any assumption on data or any number of k, that makes kNN-regression equivalent to linear regression?</p> Answer:
https://stats.stackexchange.com/questions/646366/knn-regression-vs-linear-regression
Question: <p>A simple linear regression on x1 and y yields R^2 of 0.2</p> <p>A simple linear regression on x2 and y yields R^2 of 0.1</p> <p>What is a upper and lower bound of R^2 if we do a multiple linear regression on x1, x2 and y?</p> <p>My guess on the lower bound is 0.2 if x1 and x2 are perfectly correlated, b...
https://stats.stackexchange.com/questions/268314/how-r2-values-in-simple-linear-regression-bound-r2-in-multiple-linear-regr
Question: <p>As part of my work (programmer), I need to learn some linear regression. I have a degree in pure mathematics, but not in statistics. Could anyone be able to give me a good book, an introduction, in linear regression?</p> <p>Thanks in advance!</p> Answer: <p>Linear regression is one of the core topics in ...
https://stats.stackexchange.com/questions/254763/introduction-to-linear-regression
Question: <p>I am reading a paper and come across the following information:</p> <pre><code> Predictor Dependent Variable R Square Beta P A D .12 .35 &lt;0.05 B D .16 .40 &lt;0.05 C D .13 ...
https://stats.stackexchange.com/questions/124208/linear-regression
Question: <p>I want to know the difference between linear regression in a regular machine learning analysis and linear regression in "deep learning" setting. What algorithms are used for linear regression in deep learning setting.</p> Answer: <p>Assuming that by deep learning you meant more precisely neural networks: ...
https://stats.stackexchange.com/questions/253337/what-is-the-difference-between-regular-linear-regression-and-deep-learning-lin
Question: <p>How should one decide between using a linear regression model or non-linear regression model?</p> <p>My goal is to predict Y.</p> <p>In case of simple $x$ and $y$ dataset I could easily decide which regression model should be used by plotting a scatter plot. </p> <p>In case of multi-variant like $x_1,x_...
https://stats.stackexchange.com/questions/136564/deciding-between-a-linear-regression-model-or-non-linear-regression-model
Question: <p>I am very new to linear regression analysis and I am trying to solve my first examples, most of the examples I have come across contained some tables and data where I could easily use the formulas I know and solve them. However, I have just come across an example that does not have much data and I have no ...
https://stats.stackexchange.com/questions/177371/linear-regression-analysis
Question: <p>I'm interested to know that, what is the difference between linear regression and multiple linear regression? both of them seems same to me.</p> Answer: <p>By linear regression I assume that you mean simple linear regression. The difference is in the number of independent explanatory variables you use to ...
https://stats.stackexchange.com/questions/83747/what-are-the-differences-between-the-linear-regression-and-multiple-linear-regre
Question: <p>Let's say I run a linear regression model with a binary dependent variable. If I ran logistic regression on the same data would the results be comparable or exactly similar? By results I mean both the beta values and the value of dependent variable. If not why? Also what can I say about linear regression b...
https://stats.stackexchange.com/questions/44569/logistic-vs-linear-regression
Question: <p>I am fairly new to the world of statistics and approaching it as I learn more about machine learning. I have a fairly firm grasp on regression analysis so far but not necessarily on nuances and best practices of application.</p> <p>For example; assume I have 5 predictor variables—a clear case for considera...
https://stats.stackexchange.com/questions/535464/when-to-use-simple-linear-regression-over-multiple-linear-regression
Question: <p>If you were testing the hypothesis that age would have an effect on your dv for men, but not for women, would you measure this by doing a multiple linear regression with sex and age as the predictors for your DV or by splitting the data into male/female scores and then doing a simple linear regression with...
https://stats.stackexchange.com/questions/547330/simple-or-multiple-linear-regression
Question: <p>I'm doing a linear regression, in R. The values are like this -</p> <pre><code>u &lt;- c(1,2,3,4,5,6,7,8,9,10) v &lt;- c(21,22,23,24,25,26,27,28,29,30) w &lt;- c(41,42,43,44,45,46,47,48,49,50) y &lt;- c(128.2305,132.4040,140.1732,147.3236, 154.5410, 158.7206, 165.1761, 169.7121,178.9751,181.0309) </code...
https://stats.stackexchange.com/questions/145949/multiple-linear-regression-coefficents
Question: <p>##Linear Regression Variable Selection</p> <p>Hi I am running a simple single variable linear regression model where covid deaths per 100,000 are my dependent variable and my independent variable is % of population with iron deficiency. Does it make sense to regress these two variables together or should ...
https://stats.stackexchange.com/questions/548572/linear-regression-variable-selection
Question: <p>Let's say I perform linear regression on some data that produces the following <span class="math-container">$R^2$</span>:</p> <p><span class="math-container">$\text{RSS} = 1966815.13$</span></p> <p><span class="math-container">$\text{TSS} = 2145213.91$</span></p> <p><span class="math-container">$R^2 = 0.0...
https://stats.stackexchange.com/questions/491194/hacking-linear-regression
Question: <p>I'm looking at plain linear regression was wondering about the specifics of the cost function.</p> <blockquote> <p>The cost function associated with simple linear regression is given by:</p> <p><span class="math-container">$$J(\theta) = \frac{1}{2n}\sum_{1=1}^n(y_i - \theta^tx_i)^2$$</span></p> </blockquot...
https://stats.stackexchange.com/questions/561349/linear-regression-cost-function
Question: <p>Suppose, I have a classification problem with 2 classes (0 and 1) and evaluation criteria is AUC. I used the following method: fit a linear regression and then pass its predictions through the logistic function. As far as I understand, it is not equivalent to logistic regression, because estimates of coef...
https://stats.stackexchange.com/questions/129571/linear-regression-for-classification
Question: <p>I have used a deep NN for performing regression analysis with multiple independent variables and then predicting one dependent varible.</p> <p>To understand the quality of the regression I have used <span class="math-container">$R^2$</span>, but it is typically used for linear regression.</p> <p>My questio...
https://stats.stackexchange.com/questions/506491/coefficient-for-linear-and-non-linear-regression
Question: <p>What do you mean by a distribution is homoscedastic (i.e. $ σ(Y|X = x) = σ$) in the context of simple linear regression?</p> <p>Why do we need this assumption in simple linear regression?</p> <p>What will happen to the regression if a distribution is not homoscedastic?</p> Answer: <p>When you perform a...
https://stats.stackexchange.com/questions/336101/homoscedasticity-assumption-in-simple-linear-regression
Question: <p>One way of making linear regression applicable more widely is to use basis expansions, i.e., adding more features to the input set. Suppose that the data is described by a p-tuple, $(x_1 , x_2 , . . . , x_p )$. Comment on the utility of the following sets of features. Specifically describe the family of fu...
https://stats.stackexchange.com/questions/342731/linear-regression-feature-transformation
Question: <p>I'm working on a project with R and I don't think I'm using the appropriate linear regression or plot, I've made both but they don't seem to match. The study is an ANOVA comparing $CO_2$ emissions per capita with 5 groups of income levels and a relevant linear regression. For the linear regression I want...
https://stats.stackexchange.com/questions/179498/plotting-linear-regression-with-factors
Question: <p>I am doing a linear regression and the regressors, like GDP, inflation, etc, (independent variables) are non-stationary.</p> <p>What should I do if those regressors are not stationary? Should I 'make' it to stationary before regression?</p> Answer:
https://stats.stackexchange.com/questions/323866/linear-regression-on-non-stationary-regressor
Question: <p>There is a multiple linear regression model being created.</p> <p>Y=ax1+bx2+cx3</p> <p>Following HYPOTHESES are formed</p> <p>Variable x does not impact y</p> <p>for all variables x1, x2 , x3 and so on.</p> <p>We removed a variable , say , x2 because of high VIF value from regression model but that me...
https://stats.stackexchange.com/questions/405805/linear-regression-and-multicollinearity
Question: <p>A quick perplexity popped up in my mind while reading about <em>non-parametric</em> linear regression.</p> <p>In linear regression, we model our response <span class="math-container">$\textbf{y} \sim \mathcal{N}(X\beta, \sigma^2I)$</span> so basically we try to estimate a linear function of the form</p> <p...
https://stats.stackexchange.com/questions/546954/difference-between-kernel-linear-regression-and-non-parametric-regression
Question: <p>I am new to statistics and I am trying to understand the difference between ANOVA and linear regression. I am using R to explore this. I read various articles about why ANOVA and regression are different but still the same and how the can be visualised etc. I think I am pretty there but one bit is still mi...
https://stats.stackexchange.com/questions/76250/r-anova-and-linear-regression
Question: <p>The text is from <a href="http://www.amazon.in/Introduction-Statistical-Learning-Applications-Statistics/dp/1461471370?tag=googinhydr18418-21&amp;tag=googinkenshoo-21&amp;ascsubtag=b2873fcd-dac7-4d50-8a4f-ef395872fda3" rel="nofollow">Intro to Statistical Learning</a> Page no 380.Can anyone explain the both...
https://stats.stackexchange.com/questions/208341/scaling-in-linear-regression
Question: <p><a href="https://i.sstatic.net/vLSB9.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/vLSB9.png" alt="enter image description here" /></a></p> <p>By using <a href="https://www.socscistatistics.com/tests/regression/default.aspx" rel="nofollow noreferrer">this site</a> I found the two linear re...
https://stats.stackexchange.com/questions/545954/simple-linear-regression-question-confusion
Question: <p>I can't find a proper explanation for my question on <em><a href="https://stats.stackexchange.com/tour">Cross Validated</a></em>. The closest explanation was <a href="https://medium.com/@biswajit3071976/what-does-the-term-linear-in-linear-regression-mean-97ef717bed7b" rel="nofollow noreferrer">this one</a>...
https://stats.stackexchange.com/questions/586864/why-is-a-linear-regression-not-linear-when-you-plot-it
Question: <p>I am looking how epigenetic age associated with toxic element exposure in four different road buffer zone (1000m, 2000m, 3000m, &amp;4000m) using robust linear regression. I can run robust linear regression without interaction term, but could you please help me how to run robust linear regression with inte...
https://stats.stackexchange.com/questions/641936/robust-linear-regression-with-interaction
Question: <p>Could someone explain the differences among the three? It looks to me the function form is the same so they're doing the same thing, but the potential assumption on Y distribution is different between 1 and 3. And I think 1 and 2 is exactly the same thing.</p> <ol> <li>Log Transformations on Y in a Linear ...
https://stats.stackexchange.com/questions/554641/poisson-regression-vs-log-linear-regression-vs-linear-regression-with-log-transf
Question: <p>Are the Gauss-Markov assumptions the same for Simple Linear Regression and Multiple Linear Regression? I cant seem to find the answer for this and my literature seem to suggest that they have different formulas.</p> <p>(Literature: An introduction to Econometrics - James H. Stock, Mark W. Watson.)</p> <p>...
https://stats.stackexchange.com/questions/493299/gauss-markov-assumptions-for-multiple-linear-regression
Question: <p>I'm looking to analyzing data from a study and previous studies that are similar have used either PCA or hierarchical linear regression to analyze the data. I've used both PCA and linear regression previously. From my understanding PCA breaks the data down into principal components and is useful for learn...
https://stats.stackexchange.com/questions/410516/using-pca-vs-linear-regression
Question: <p>I have a sample of 412 young subjects, measured twice in an interval between 20 days and 3 years. I am interested in how two external factor (lets say sunlight and ice-cream) relates to growth. Subjects were exposed to sunlight and ice-cream somewhat randomly, and I have calculated the cumulative exposure ...
https://stats.stackexchange.com/questions/358606/correlated-regressors-in-linear-regression
Question: <p>Does log-linear regression fall into the class of generalized linear models? Here I'm defining "log-linear regression" as the model $\log(y) = x'\beta + \eta$ where $\eta \sim N(0, \sigma^2)$.</p> <p>Thanks.</p> Answer: <p>Normally, loglinear models <em>for contingency tables</em> are considered as gener...
https://stats.stackexchange.com/questions/330412/is-log-linear-regression-a-generalized-linear-model
Question: <p>Are the slope and intercept of a simple linear regression model always normally distributed? </p> <p>Is there ever a difference between the distribution of the estimated slope and intercept and the actual ones? </p> <p>I have only just begun learning about the subject but I am still not clear on the deta...
https://stats.stackexchange.com/questions/60094/linear-regression-parameters-question
Question: <p>I have a time series dataset. The,</p> <p>X (Independent variable) is time and is denoted as 1,2,3,4,5,6..1000.etc Y (Dependent variable ) is a percentage scale as 99%, 98.7%, 96%, 91% ...etc. This is a continuous data set. </p> <p>I have 1000 such data points. The first 700 data points used as training ...
https://stats.stackexchange.com/questions/201299/linear-regression-vs-logistic-regression
Question: <p>I run linear regression with Posttest scores as DV and Pretest scores and Group as IVs. Collinearity Statistics Tolerance shows .998 both for Pretest and Group (VIF 1.002). Is this one of the situations where violating Collinearity might be ignored?</p> Answer: <p>I think you are misinterpreting what tole...
https://stats.stackexchange.com/questions/146694/linear-regression-multicollinearity
Question: <p>I wish to run a linear regression model, with a dependent variable Y and several explanatory variables.</p> <p>The distribution of Y looks like this:</p> <p><a href="https://i.sstatic.net/g6JZZ.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/g6JZZ.png" alt="enter image description here"></...
https://stats.stackexchange.com/questions/341880/linear-regression-with-bootstrapping
Question: <p>I am reading <a href="https://www.crcpress.com/Statistical-Rethinking-A-Bayesian-Course-with-Examples-in-R-and-Stan/McElreath/p/book/9781482253443" rel="nofollow noreferrer">Statistical Rethinking (Section 4.2)</a>.</p> <p>When defining the components of a model description the author says:</p> <blockquote...
https://stats.stackexchange.com/questions/328305/likelihood-distribution-for-linear-regression
Question: <p>I am currently trying to build an algorithm to predict a continuous output (Y) from a list of predictors (X). My first idea was to use a simple linear regression to see how it performs. Distribution of residual errors is not normal.</p> <p>I have a lot of data and I was wondering if I can take advantage t...
https://stats.stackexchange.com/questions/117838/using-several-linear-regression
Question: <p>Can someone please differentiate logistic regression vs linear regression? I know that logistic regression is discrete (1, 0) and Linear regression is continuous. Could you provide two examples that set the two apart? Im just really confused on when to use which.</p> Answer: <p>You answered the question b...
https://stats.stackexchange.com/questions/311591/logistic-vs-linear-regression-difference
Question: <p>I understand that linear regression is finding the "best fitting line" and Pearson's r is measuring correlation between two variables, but I can't visualize this difference.</p> <p>I had a project where I was finding if certain brain cancers were correlated to age, or sex for example, and I was advised to...
https://stats.stackexchange.com/questions/397083/linear-regression-vs-pearsons
Question: <p>I need to run hundreds of linear regression models, with the same set of independent variables, but with varying dependent variables. I have checked normality for a few dozens. Some are normally distributed and some are not. </p> <p>My intention, for practical reasons, is to write a macro that will run th...
https://stats.stackexchange.com/questions/223004/alternative-to-linear-regression
Question: <p>How do we decide whether mean absolute error or mean square error is better for linear regression? Are there other loss functions that are commonly used for linear regression?</p> Answer: <p>Put simply: it matters what error metric matters most to you. I have not personally seen a useful application of ab...
https://stats.stackexchange.com/questions/380099/loss-function-of-linear-regression
Question: <p>I want to demonstrate a possible association between a dichotomous independent variable and a continuous dependent variable. Therefore, I wanted to use a linear regression analysis. However, the dependent variable is not normally distributed, while normality is an assumption of linear regression analysis. ...
https://stats.stackexchange.com/questions/463082/linear-regression-analysis-assumptions-not-met
Question: <p>We know that the neural network will perform like a linear regression if there is only one hidden unit. So, the NN method should perform at least as well as a linear regression method. I have built a tidymodel model using the following line of code:</p> <pre><code>Data_nnet_mod &lt;- mlp(hidden_units = tu...
https://stats.stackexchange.com/questions/582202/neural-network-vs-linear-regression
Question: <p>Both correlation and linear regression explain the linearity in data but to get a high correlation coefficient the data must be linear with a slope close to 1. In some cases you can have linear data that can be fit on a regression line with a slope less than one, in which case the correlation coefficient w...
https://stats.stackexchange.com/questions/473112/correlation-vs-simple-linear-regression
Question: <p>I'm analysing some data where I would like to perform ordinary linear regression, however this is not possible as I am dealing with an on-line setting with a continuous stream of input data (which will quickly get too large for memory) and need to update parameter estimates while this is being consumed. i....
https://stats.stackexchange.com/questions/6920/efficient-online-linear-regression
Question: <p>I am struggling to get ANN to estimate constant and coefficients of a linear regression problem. Unfortunately my results are way off from the expected. Kindy take a look at the reproducible code below.</p> <pre><code>from sklearn import datasets from sklearn.model_selection import train_test_split X, y ...
https://stats.stackexchange.com/questions/442294/linear-regression-coefficients-through-ann
Question: <p>what this sentence means&quot;The correlation squared (r2 or R2) has special meaning in simple linear regression. It represents the proportion of variation in Y explained by X&quot;.</p> Answer:
https://stats.stackexchange.com/questions/532147/correlation-and-simple-linear-regression
Question: <p>I do experiments with a certain parameter x. The result is y. I assume y is linearly related to x.</p> <p>Suppose I can do 1000 experiments, which method will give me a better estimation of the linear relation?</p> <ul> <li>Select 1000 different values of x, get a single y for each x, and do linear regre...
https://stats.stackexchange.com/questions/43209/linear-regression-and-arithmetic-mean
Question: <p>I would like to perform a simple linear regression on data that shows a clear linear relationship.</p> <p>How to determine the minimum sample size for a simple linear regression analysis?</p> <p>My sample size is small, so even if the linear relationship is evident, I don't know how to determine if the s...
https://stats.stackexchange.com/questions/448977/linear-regression-minimum-sample-size
Question: <p>Linear regression using the method of least squares estimates the conditional mean of the response variable across values of the predictor variables.</p> <p>Quantile regression estimates a conditional quantile of the response variable across values of the predictor variables.</p> <p>The least squares metho...
https://stats.stackexchange.com/questions/564642/linear-regression-and-quantile-regression
Question: <p>I have heard people describe logistic regression as linear regression except as it is deployed for classification. But I have heard the exact same comment about LDA (linear discriminant analysis). Out of logistic regression and LDA, which is closer to what happens in linear regression?</p> Answer: <p>They...
https://stats.stackexchange.com/questions/523340/is-classification-using-linear-regression-called-logistic-regression-or-linear-d
Question: <p>I am new to ML and I am learning the different algorithms one can use to perform regression. Keep in mind that I have a strong mathematical background, but I am new in the ML field.</p> <p>So I understand the math behind Support Vector Regression and behind Linear Regression. Now I just want to understand ...
https://stats.stackexchange.com/questions/633091/support-vector-regression-vs-linear-regression
Question: <p>I have a problem where I need to calculate linear regression as samples come in. Is there a formula that I can use to get the exponentially weighted moving linear regression? Not sure if that's what you would call it though.</p> Answer: <p>Sounds like what you want to do is a two-stage model. First trans...
https://stats.stackexchange.com/questions/9931/exponentially-weighted-moving-linear-regression
Question: <p>Suppose we observe $x$ and $y$ and we want to predict at $x=5$. A naive way would be to take each observation and compute $5/(x/y)$ or similarly $5*(y/x)$ and then take the overall mean. Thi is basically rescaling each observation to the unit scale and then extrapolating to 5.</p> <p>A more sophisticate...
https://stats.stackexchange.com/questions/208259/linear-regression-prediction-vs-extrapolation-prediction
Question: <p>I've been reading some literature that discusses 'linear factor models' which appear to describe the general equation often used in OLS regression. When people refer to a 'linear regression model' are they essentially just referring to a linear factor model? Where does the term linear factor model fit in...
https://stats.stackexchange.com/questions/111231/linear-factor-model-vs-linear-regression-model
Question: <p>I have measured the area of spread of a number of plants through time. I'm interested in trying to ascertain whether a linear or a non-linear relationship (i.e. quadratic) best represents the increase in the sqrt of the area occupied by these plants through time </p> <p>My first feeling was that I could u...
https://stats.stackexchange.com/questions/194236/linear-regression-to-detect-between-a-linear-and-non-linear-trend
Question: <p>Employees Salary = 3000 + x(Employee Age)^2, is this a Linear Regression?</p> Answer: <p>First, for there being a regression, there should be parameters! I will assume 3000 and 1 are in this case</p> <p>It is linear regression if you consider your "employee age squared" as a variable, so, strictly speaki...
https://stats.stackexchange.com/questions/397287/is-the-equation-is-linear-regression
Question: <p>I have the following multiple linear regression model:</p> <pre><code>Call: lm(formula = Y ~ X1 + X2 + X2 + X3 + X4 + X5 + X6 + X7, data = my.model, na.action = na.omit) Residuals: Min 1Q Median 3Q Max -43.836 -1.507 0.010 1.485 46.231 Coefficients: Estimat...
https://stats.stackexchange.com/questions/27700/linear-regression-forecast-underestimation