Good day everyone,
I am still an undergrad student so please excuse any elementary questions.
I am busy with a project on trade. The data set has import and export countries (i.e. bilateral) across several years (with year and month columns too), which also shows the different products traded together with their monetary values and quantities. However, it should be noted that the values and quantities are entered on a monthly basis. I created country pairs (and allocated numerical values to these). All I really want to do is create a line graph depicting the trade of the different products for each year with the monthly aggregates of each product within that specific year for the specified country pair. And then, a line graph with the yearly totals for each product trade in the specified country pair.
However, to do this I need to aggregate the monthly values for the specified product and country pair first for the specified year and from a whole lot of Googling, thought I might need to do something with the collapse command.
Any assistance would be greatly appreciated as it is of great urgency.
Related Posts with Aggregating variables
Panel data tobit and marginal effectAbout xttobit "re" I have 3years panel data and try to estimate correlation between damage cost of d…
How do you determine if you should use a quadratic term or a cubed term?Is there a test to determine if you should use a quadratic term or a cubed term? …
How to choose which duplicates to drop/keep?Hi there, I'm working on data from 2012-2018 concerning HIV-positive pregnant women in treatment an…
Replacing values of multiple variables at onceI have 9 variables (v1 - v9) with binary responses coded as yes = 1 no =2. I want to replace all he…
user written program for sample size of diagnostic testHello all, Does anyone know about how to or any community contributed Stata program for calculating…
Subscribe to:
Post Comments (Atom)
0 Response to Aggregating variables
Post a Comment