Hi
I am using Stata 15. My data is a panel data set for 300 districts from 1980 to 2015. I have three variables crop YIELD (in kg per hectare), TEMPERATURE (in degree Celsius), and EXPOSURE (number of days that the temperature was of a certain degree ).
I am trying to replicate a graph that shows the relation between temperature and yields in the ‘upper panel’ and a histogram of temperature and number of days in the ‘lower panel’.
The replication is from the following paper Schlenker and Roberts (2009) (https://www.pnas.org/content/pnas/106/37/15594.full.pdf) and the graph looks as follows.
Initially I thought it could be something like


Array
Initially I thought it could be something like

Code:
graph twoway (bar TEMPERATURE EXPOSURE) (line TEMPERATURE YIELD, lc(black))
But evidently this is not even close to what i am supposed o be doing. Additionally the study mentions that the graphs in the upper panels are "based on regressions", so I am not sure how to start plotting them.
Any suggestions?