Announcement

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

  • Make Two Transformations in Coeflot

    I'm using the coefplot function and I want to know the proper syntax for making two transformations using the "transform()" option. Specifically, I'm trying to subtract 100 from each value *and* set the maximum value of the confidence intervals to 5 because the confidence intervals are currently too large. Thanks!


    Last edited by Josh Schwartz; 18 Mar 2021, 09:09.

  • #2
    Leaving aside the issue of manually adjusting confidence intervals, you can use the -transform()- option for both tasks:

    Code:
    clear
    sysuse auto
    regress price mpg  turn trunk
    coefplot, drop(_cons)  xlabel(-600 -400 -200  5 300 )  name(gr1,replace)
    
    coefplot, drop(_cons)   transform(* = min(5,(@-100))) ///
        xlabel(-600 -400 -200  5 300 ) name(gr2,replace)
    graph combine gr1 gr2, col(1)
    Click image for larger version

Name:	Graph.png
Views:	1
Size:	13.2 KB
ID:	1598608

    Comment


    • #3
      Thanks so much Scott!

      Comment

      Working...
      X