createPlotView            package:iSPlot            R Documentation

_C_r_e_a_t_e _a _P_l_o_t _V_i_e_w

_D_e_s_c_r_i_p_t_i_o_n:

     createPlotView calls a function based on the plotType, which then
     creates the actual plot.  Currently, the only available plotType
     is "sPlotView", so only a scatterplot can be created.  When the
     plotType is "sPlotView" the function, createSPlotView, is called.  

     createSPlotView creates an object of class sPlotView and calls 
     scatterplot to create the actual plot.  Then createSPlotView adds
     the  button press and motion notify events to the drawing area.

_U_s_a_g_e:

     createPlotView(win, dfName, plotType, ...)
     createSPlotView(win, dfName, drArea, dfRows, dfColumns)

_A_r_g_u_m_e_n_t_s:

     win: the gtk window 

  dfName: the data name, a character string 

plotType: the plot type, currently only "sPlotView" is available 

     ...: extra parameters needed for createSPlotView 

  drArea: the gtk drawing area 

  dfRows: the dataframe rows to be plotted 

dfColumns: the dataframe columns to be plotted, the first column will
          be the x values and the second column will be the y values 

_V_a_l_u_e:

     Both createPlotView and createSPlotView return the new view
     object.

_A_u_t_h_o_r(_s):

     Elizabeth Whalen

_S_e_e _A_l_s_o:

     'createView', 'createDataView', 'scatterplot', 'sPlotView-class',
     'clickEvent', 'motionEvent'

_E_x_a_m_p_l_e_s:

       if (interactive())
       {
         createControlWindow()
         # should load data through Open Data or Open File under the File menu
         data(USArrests)
         loadDFData(USArrests,"USArrests")
         # plotting the data should occur through Plot Data under 
         # the Display menu
         # here you can see the extra parameters needed for the plot view
         createView(type = "plotView", dataName = "USArrests", 
                    plotType = "sPlotView", dfRows = 1:nrow(USArrests), 
                    dfColumns = 1:2) 
         # createView will call createPlotView, which will call createSPlotView
       }

