Label obs in a scatter plot
Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason
Label obs in a scatter plot
Hi, I created a workfile with three series. The first one is country names and so it is an alpha series. The second and third are GDP and inflation for each country. Now I generate a scatter plot with GDP on the X axis and inflation on the Y. But my problem is that, when I tried to label each observation in the scatter plot with its country name, I clicked on Graph Opinions -> Axes and Scaling -> Obs/date axis, it shows that "Graph has no obs/date axis" in the Axis Assignment box. The Axis Labels where I am supposed to type in the alpha series is gray and does not allow me to do so. Could you please help me out? Thanks!
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
Enter the name of the alpha series in the box on the right that says "Optional alpha or series to use for observation labels".
Re: Label obs in a scatter plot
Yes, I tried that before I posted the question here. That box area is gray and does not allow to type in anything. It says: "Series labels cannot be used with this graph." The reason I guess, as said in the original post, is that "Graph has no obs/date axis." as shown in the Axis Assignment box. How can I fix it? Thanks a lot!
Enter the name of the alpha series in the box on the right that says "Optional alpha or series to use for observation labels".
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
Describe exactly what you've done.
Re: Label obs in a scatter plot
As said in the original post, I created a workfile for cross-sectional data. The data were imported to EViews and so there were three series in that workfile, Country (names), GDP, and Inflation. I opened GDP and Inflation as a group and the country names are shown on the left as identifier. But when I graph a scatter plot with GDP on the X axis and Inflation on the Y, I tried to label each observation with its country name. You said there is a place saying that "Optional alpha or series to use for observation labels". I saw that place is frozen in gray, showing "Series labels cannot be used with this graph."
Describe exactly what you've done.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
If the workfile is already structured with country as the ID series, then the scatter will automatically get those names as the obs label.
You can only provide an alternative set of labels if the workfile is not already structured by one.
You can only provide an alternative set of labels if the workfile is not already structured by one.
Re: Label obs in a scatter plot
How do I know "if the workfile is already structured with country as the ID series"? I open the group of GDP and Inflation and see each country's name lined up (in blue) on the far left side of the window. Does this mean it is structured with country as the ID series? If so, that is where I am and I do not see the scatter automatically get the names on the obs label.
If the workfile is already structured with country as the ID series, then the scatter will automatically get those names as the obs label.
You can only provide an alternative set of labels if the workfile is not already structured by one.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
Yes, if the country names show on the spreadsheet view, then it is structured that way. What obs labels do you see if not the country names?
Re: Label obs in a scatter plot
EViews says "Graph has no obs/date axis". I don't see any obs labels on the scatter.
Yes, if the country names show on the spreadsheet view, then it is structured that way. What obs labels do you see if not the country names?
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
Turn obs labeling on.
Graph Options->Graph Elements->Symbol/Obs Label.
Graph Options->Graph Elements->Symbol/Obs Label.
Re: Label obs in a scatter plot
What I see on my EViews 8 is Graph Options -> Graph Elements and I do not find "Symbol/Obs Label".
What I found is that there are four modules under Graph Elements: Lines & Symbols, Fill Areas, Bar-Area-Pie, and Boxplots. Which one I should go with? I clicked on Lines & Symbols and did not find anywhere I could turn on obs labeling.
What I found is that there are four modules under Graph Elements: Lines & Symbols, Fill Areas, Bar-Area-Pie, and Boxplots. Which one I should go with? I clicked on Lines & Symbols and did not find anywhere I could turn on obs labeling.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
...
- Attachments
-
- 2014-03-04_163329.png (23.82 KiB) Viewed 11678 times
Re: Label obs in a scatter plot
So, where can I turn on obs label on the page you showed? Just choose "Auto Choice" and/or "Symbol Only"? I did both and it made no difference. Still says "Graph has no obs/date axis" and no obs label shows up.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Label obs in a scatter plot
Post your workfike
Re: Label obs in a scatter plot
Below are the images of workfile, obs/date axis, and graph elements, respectively. Thanks!
Who is online
Users browsing this forum: No registered users and 2 guests
