I would like to know the code to create a bar graph with the values of the receipts of each group by year. Therefore, in each year it should appear 4 bars with the values for "scandinavian", "continental", "anglo-saxon" and " mediterranean" groups.
I send an example of the data:
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input str52 country int year float(mean_receipts groups) "Belgium" 1995 43.7 2 "Denmark" 1995 47.9 1 "Spain" 1995 33.866665 4 "Ireland" 1995 32 3 "United Kingdom" 1995 32 3 "Austria" 1995 43.7 2 "Greece" 1995 33.866665 4 "Italy" 1995 33.866665 4 "Ireland" 1996 33.6 3 "Austria" 1997 43.03333 2 "Luxembourg" 1997 43.03333 2 "Belgium" 1997 43.03333 2 "Italy" 1998 41 4 "United Kingdom" 1999 33.4 3 "Netherlands" 1999 37.7 1 "Luxembourg" 2000 42.63334 2 "Austria" 2000 42.63334 2 "Ireland" 2000 31.8 3 "Denmark" 2000 47.83333 1 "Italy" 2000 36.166668 4 "Belgium" 2000 42.63334 2 "Finland" 2000 47.83333 1 "Sweden" 2000 47.83333 1 "Spain" 2000 36.166668 4 "Greece" 2000 36.166668 4 "Finland" 2003 45.1 1 "Portugal" 2003 34.9 4 "Greece" 2003 34.9 4 "Sweden" 2003 45.1 1 "Denmark" 2003 45.1 1 "Luxembourg" 2003 42.975 2 "France" 2003 42.975 2 "Spain" 2003 34.9 4 "Italy" 2003 34.9 4 "Ireland" 2003 29.7 3 "Belgium" 2003 42.975 2 "Austria" 2003 42.975 2 "Ireland" 2004 32.45 3 "Spain" 2004 34.825 4 "Belgium" 2004 42.675 2 "Italy" 2004 34.825 4 "Luxembourg" 2004 42.675 2 "United Kingdom" 2004 32.45 3 "Sweden" 2004 42.75 1 "Finland" 2004 42.75 1 "Portugal" 2004 34.825 4 "Greece" 2004 34.825 4 "Austria" 2004 42.675 2 "Denmark" 2004 42.75 1 "France" 2004 42.675 2 "Netherlands" 2004 42.75 1 "Italy" 2005 35.625 4 "France" 2005 42.75 2 "Austria" 2005 42.75 2 "Netherlands" 2005 43.5 1 "Belgium" 2005 42.75 2 "Finland" 2005 43.5 1 "United Kingdom" 2005 32.9 3 "Denmark" 2005 43.5 1 "Sweden" 2005 43.5 1 "Luxembourg" 2005 42.75 2 "Ireland" 2005 32.9 3 "Spain" 2005 35.625 4 "Greece" 2005 35.625 4 "Portugal" 2005 35.625 4 "Netherlands" 2006 43.125 1 "Luxembourg" 2006 42.15 2 "Spain" 2006 36.025 4 "Denmark" 2006 43.125 1 "United Kingdom" 2006 33.65 3 "Ireland" 2006 33.65 3 "Belgium" 2006 42.15 2 "Italy" 2006 36.025 4 "Portugal" 2006 36.025 4 "Austria" 2006 42.15 2 "Finland" 2006 43.125 1 "Sweden" 2006 43.125 1 "Greece" 2006 36.025 4 "France" 2006 42.15 2 "Ireland" 2007 33.4 3 "Greece" 2007 36.7 4 "Finland" 2007 42.55 1 "Italy" 2007 36.7 4 "Spain" 2007 36.7 4 "United Kingdom" 2007 33.4 3 "Belgium" 2007 42.025 2 "Netherlands" 2007 42.55 1 "Luxembourg" 2007 42.025 2 "Denmark" 2007 42.55 1 "France" 2007 42.025 2 "Austria" 2007 42.025 2 "Portugal" 2007 36.7 4 "Sweden" 2007 42.55 1 "Sweden" 2008 41.875 1 "Austria" 2008 42.525 2 "Netherlands" 2008 41.875 1 "Spain" 2008 35.6 4 "France" 2008 42.525 2 "Ireland" 2008 32.95 3 "Italy" 2008 35.6 4 end format %ty year label values groups gnames label def gnames 1 "Scandinavian", modify label def gnames 2 "Continental", modify label def gnames 3 "Anglo_Saxon", modify label def gnames 4 "Mediterranean", modify
Thank you in advance.
0 Response to Histogram by groups
Post a Comment