Hi all,
I am using the margins command to predict probabilities. I ran 5 separate logistic regression for each subgroup (block) of my sample.
foreach blo of numlist 1(1)5 {
logit y x1 x2 x3 x4 if block==`blo'
qui margins if block==`blo', at((mean) _all x1=(1(1)10)) over(x2))
.....
}
My question is: for the part at((mean) _all x1=(1(1)10)) over(x2)) , is margins predicting the probabilities at the means of covariates x3 and x4 within each block (i.e. block-specific means), or at the means of x3 and x4 of the whole sample? If it is the latter, is there any efficient way of telling Stata to do it at the block-specific means of x3 and x4?
Thank you very much!
Related Posts with margins at((mean) _all)
ANOVA test for clusteringHi, I want to check whether there is a need to cluster my results. I am doing a panel regression re…
Automate file names using current dateHi All! I'm trying to create a local string reflecting the current date in the format, "YYYY-MM-DD"…
Storing Hausmann test values for each yearHi All, I have data that resembles the following: Code: * Example generated by -dataex-. To ins…
using tabstat for mean annual procedure volumeGood morning, I have a dataset of companies (ik), case-number, year, procedure-type and quintiles. …
outreg2Good morning, I am looking to create a table for logistic regression results, with a title, odds rat…
Subscribe to:
Post Comments (Atom)
0 Response to margins at((mean) _all)
Post a Comment