Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Coefplot, changing formatting in stored results

    I'm trying to use coefplot to graph average predicted probabilities after a logit regression but without going into detail as to why, I need to report the results as percentages. Meaning I need to multiply the stored results by 100 and add a % for the label. The example below is not the data I'm working with but it is similar. Instead of showing 0.2408 for white, I'd like to show 24%
    Can someone help with this?

    Code:
    clear
    use https://www.stata-press.com/data/r16/lbw
    
    logistic low age4 lwt i.race i.smoke i.ptl i.ht i.ui
    margins i.race i.smoke i.ptl i.ht i.ui , post
    estimates store a
    coefplot a, title("Average Predicted Probability of Low Birth Weight", size(med.small)) xline(0)  omitted baselevels mlabel format(%9.4f) mlabposition(2) mlabsize(vsmall)
    Click image for larger version

Name:	GraphExample.jpg
Views:	3
Size:	42.4 KB
ID:	1707688
    Attached Files

  • #2
    https://www.statalist.org/forums/for...stored-results

    Last edited by Andrew Musau; 30 Mar 2023, 01:53.

    Comment

    Working...
    X