Announcement

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

  • cmissing having no effect

    I am trying to create a line graph that does not connect when there are observations with missing data. The cmissing option does not appear to be functioning as I expect it would. Using an example given in a previous answer on this topic (https://www.statalist.org/forums/for...issing-command), I would think the following code would have a line broken in the middle:
    Code:
    webuse grunfeld,clear
    replace invest = .  if inrange(year, 1940, 1950)
    twoway line invest year if com == 1, cmissing(n)
    However, I get a single line with the points connecting Click image for larger version

Name:	Graph.png
Views:	2
Size:	33.1 KB
ID:	1513375

    Any help is appreciated.
    Attached Files

  • #2
    Yes, I have started getting a similar experience using tsline with cmissing(no). However, if I copy your code into Stata 13 it works as we expect it to work showing the gap. cmissing() was working earlier in version 15.

    Comment


    • #3
      Updating Stata corrected the problem. Thank you Stata!

      Comment

      Working...
      X