# Questions tagged [weighted-regression]

Weighted least squares regression is a generalization of OLS regression used when different data points have different importance, or "weights". See also [weighted-data].

341 questions
Filter by
Sorted by
Tagged with
82 views

### How do I calculate weights for weighted means?

I want the weighted mean of my dv, velocity. In this scenario, velocity is a derived/interpolated measure comprised of repeated measures of randomly sampled speeds in a given region. There will always ...
• 173
39 views

### What's the meaning of an increased SMD after inverse propensity weight matching?

I made an inverse propensity weight matching for my research project (two groups, treated and control) and after I observed for some covariates an increased standardized mean difference. What is its ...
35 views

### Predicted y on IPW (Inverse Probability Weighted) logistic regression

I am performing a logistic regression where the original data has unbalanced classes, 5% 1s and 95% 0s. Using IPW (either by calculating the weights myself or by choosing class_weight='balanced' in ...
• 63
9 views

### How to apply weights to the the data of 1k sample to represent whole population when I am provided with weights?

Need help to understand: I have a citizen poll data that has entries about how people(male/female), age, employment status, education, country, opinion on current government, etc. now the company who ...
• 1
63 views

### Is there a way in R to include weights in a cox regression with Firth's penalized likelihood?

I am trying to fit a propensity score weighted cox regression model in R. However, one of the treatment groups has zero events, so I also need to use an adjustment method (Firth's penalized likelihood)...
57 views

### Comparing weights in SPSS regression and R lm

In SPSS, you can use a variable as WLS Weight when carrying regression. In R, you can use a variable as an argument weight in <...
• 463
178 views

### What is the Matrix form of the prediction interval for Weighted Least Squares Regression

For ordinary least squares, I know the confidence interval is $\hat{Y} ± t\cdot\sqrt{\hat{\sigma}^2 * x_{new}(X^{\top}X)^{-1}x_{new}^{\top}}$ and $X$ is the design matrix, n is the number of ...
52 views

### Combining standard errors of two separate variables

I have a dependent variable associated with a SE and an independent variable associated with a SE. I would like to weight my regression such that both of these SEs are taken into account. What is the ...
• 41
14 views

### Outputting the weighted version of a variable

Is it possible to apply weights to a variable (eg, the independent variable in a regression analysis) and then output the weighted version of this variable? I would like to weight both my dependent ...
• 41
15 views

### What does it mean when variables in in (probability) weighted regression are significant but variables in an unweighted regression are not?

I'm running to regressions. One with probability weights inputted and another one without. When running them, my results indicate that some unadjusted variables are insignificant, but those same ...
76 views

### Fitting a Prentice-weighted PH Cox regression to case-cohort data and predicting scores based on new data

I am trying to fit a proportional hazards regression model to case-cohort data (where cases are oversampled and not representative of the population). I am using the Survival package and cch() ...
26 views

### glmnet with weighted penalty

I need to fit a elastic net penalized logistic regression model in the form of Here W is a positive definite weight matrix. Since ...
• 283
1 vote
41 views

### Survival analysis of a stratified case-cohort study in R

I am trying to perform a survival analysis for a stratified case-cohort study (1:2) where cases are patients with distant recurrence (DR) and the cohort is composed by patients without distant ...
1 vote
21 views

### Meta-regression for continuous data - effect size or otherwise?

I'm trying to parse the output of multiple studies to quantify how age impacts the prevalence of HPV in Europe. Thanks to an excellent suggestion in a previous question, it has been suggested that ...
• 251
73 views

### Is it possible to estimate IPTW in two different subgroups to evaluate interaction? (Subgroup Balancing Propensity Score?)

This questions needs a toy example to be explained. I apologize if the question is not clear. Suppose we have an observational study in which we want to evalute the association between exposure to ...
• 718
473 views

### IPTW in Cox Regression model using the WeightIt package - Question on ATT vs. ATE interpretation

I am currently trying to perform some IPTW adjustment in the context of Cox Regression models. I was interested in expanding my understanding of the differences between ATE vs. ATT estimation. I've ...
• 718
19 views

### Weighting the R-squared as a measure of goodness-of-fit in Linear Regression [duplicate]

I have two observed time series $x_i$ and $y_i$ and I want to test if $x_i$ is a good predictor of of $y_i$. So I run a simple linear regression Y ~ X and use $R^2$ as a measure of goodness of fit. ...
• 1
1 vote
156 views

• 217
1 vote
126 views

### How to address twang package warnings in mnps function [closed]

I am using twang package as I have an analysis where I want to compare 3 categories and want to compute propensity scores to include as weights in the regression ...
1 vote
63 views

### Macro version of RMSE

I want to calculate the error of a prediction on an imbalanced dataset, i.e.: ...
• 133
145 views

### Weighted cox regression: test for goodness of fit?

I want to do a weighted Cox regression analysis (coxphw command in R) since there is violation of proportional hazards assumption in standard Cox model shown by Schoenfeld residuals. What would be the ...
• 11
In performing Iteratively Reweighted Least Squares (IRLS) to derive $\hat{\beta}$ estimates for logistic regression, all the resource I've read online say to use weights inversely proportional to the ...