Official Website is http://yuanchao-xu.github.io/gfer, where manuals and more details can be found.
gfer is an R package, designed for green finance and environmental risk research. Focuses on data collecting and analyzing in green finance and environmental risk research and analysis. Main function includes environmental data collecting from official websites like MEP (Ministry of Environmental Protection of China, http://www.mep.gov.cn), water related projects identification and environmental data visualization.
If you feel gfer is of a little help, please cite it as following:
Yuanchao Xu (2016). gfer: Green Finance and Environmental Risk. R package version 0.1.3. https://CRAN.R-project.org/package=gfer
Data collection part contains different reliable sources, e.g., Ministry of Environmental Protection, Ministry of Water Resource, etc.
Usually the functions will provide an option for you to choose whether you want to use a proxy to get the data, if nothing specified, your real ip will be used to scrape the data. You can also choose to use the free proxy provided by http://www.free-proxy-list.net/.
install.packages("gfer")
install.packages('devtools')
# Ignore the warning that Rtool is not installed, unless you want other #function from devtools.
# If you have "devtools" installed already, you just need to run the following code.
devtools::install_github('Yuanchao-Xu/gfer')
During the installation of the development version, if there is some error, you can just follow the error message and reinstall the package with error. The most common message is
cannot remove previously installed XXX package.
or
error in installation of XXX package.
If so, just use install.pakcages('xxx') to reinstall XXX package. And then reinstall hyfo again. Other errors can be solved by directly reinsalling hyfo.
tar.gz and zip formats are provided.This part contains different reliable sources, which is included in the documentation of each function. If source needs to be checked, just type in ??functionname.
Data comes from PPP center established by the ministry of Finance of China.
Just one line of code, setting up starting page and end page.
library(gfer)#load the package.
a <- getPPPList(1,3) #get the ppp projects from the 1st page to the 3rd page
# then a can be write to a text file or excel file
Data from MEP data center, the webpage contains data from different intersections in each catchment, including different water quality parameters.
# get data from 1st station to 5th station of the 3rd week of 2016
a <- getWaterQ_MEP_all(2016, 3, 1, 5)
# then a can be write to a text file or excel file
Data from Hexun, Hexun provides different CSR ratings and reports from different companies of each year.
a <- getCSRRating(1,3)
# then a can be write to a text file or excel file