With great delight, I was reviewing some of Nick Cox's presentations and notes on data visualization with Stata and have been experimenting with sparkline this morning.
The structure of my dataset is as follows: panel data on >100 farm fields, each of which has 8 strips (4 treatment and 4 control strips). In hopes of comparing treatment and control trends for each farm, I used the following code structure:
sparkline y year if (var1==1 | var2==1) & (var3=="AMS" | var3=="Control") & var4=="z", over(var3) by(field) extremes
The sparklines produced also have a vertical bar in each time period where the outcome variable is observed that seems to represent the range of y over the 4 Treatment and 4 Control strips in each time period (based upon adding the extremes option). However, my question is, how are the starting and ending point for the sparkline determined with the scaling defaults?
I've included a scrubbed example of the corresponding visual.
Array
Thanks.
Maria
Related Posts with question about sparkline with by() and over()
time series prediction assignmentBackground: As a researcher at the financial economics research department of the Federal Reserve Ba…
Panel data, want to see the regression results for two time periods and country setsHi, I have a panel dataset of with a variable country, year, university, sat score. (Similar variabl…
Increase in the number of observations after using RESHAPE commandDear community, My original data are in long shape. When I reshape long to wide there is an increas…
Dummy VariableHow do I create a dummy variable which takes the value 1 in a household when first two children are …
Asgen with missing observations for the weightDear Forum, I have a short question regarding the ASGEN command with weights. I am creating value w…
Subscribe to:
Post Comments (Atom)
0 Response to question about sparkline with by() and over()
Post a Comment