[R] Adapt sweave function to produce an automatic pdf.

Frederic Ntirenganya ntfredo at gmail.com
Thu Nov 20 11:03:40 CET 2014

Hi All,

I want to make a climate method ("sweave_function"). The aim is to be able
to adapt sweave code that produces an automatic pdf so that it can works
for my climate object. i.e. instead of compile pdf, I call :
data_obj$sweave_function() and get the pdf. for instance I have
boxplot_method() and I want to output it in this way. Thanks for the help!!!

Ex: This how I started but I don't understand how I can proceed.

climate$methods(sweave_function = function(climate_data_objs_str,
) {

  #  This function returns the pdf using sweave function in R
  #  The required arguments are:
  #   climate_data_objs_str  : list of the names of climate data objects in
the climate object
  #   climate_data_objs_ind  : list of the indices of climate data object
in the climate object
  #   note that one of the above arguments is enough.


  # get_climate_data_objects returns a list of the climate_data objects
  # in the arguements.
  # If no objects specified then all climate_data objects will be taken by

  climate_data_objs = get_climate_data_objects(climate_data_objs_str,

Frederic Ntirenganya
Maseno University,
African Maths Initiative,
Email: fredo at aims.ac.za

	[[alternative HTML version deleted]]

More information about the R-help mailing list