getChangeDFData            package:iSPlot            R Documentation

_D_e_t_e_r_m_i_n_e _t_h_e _d_a_t_a _n_e_e_d_e_d _t_o _u_p_d_a_t_e _a _d_a_t_a_f_r_a_m_e

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

     getChangeDFData is called by the function, updateDFBysPlot, when a
     data set needs to be changed in response to user interaction with 
     a scatterplot. getChangeDFData returns the data that will be
     needed to  update the data set based on the view mode.  Updating
     the data set occurs  in the handleMessage method of
     gUpdateDataMessage.

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

     getChangeDFData(curPlot, curPoint)

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

 curPlot: the active plot (of type sPlotView) returned by getActivePlot 

curPoint: the point returned by identifyPoint 

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

     getChangeDFData returns a list depending on the view mode, which
     may  contain the following items. 

  dfName: the dataframe name

   Rname: the row name

   Cname: the column name

    data: the new data that will be put in the data set 

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

     Elizabeth Whalen

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

     'updateDFBysPlot', 'gUpdateDataMessage-class'

_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
         createView(type = "plotView", dataName = "USArrests", 
                    plotType = "sPlotView", dfRows = 1:nrow(USArrests), 
                    dfColumns = 1:2)  
         # should set the view mode using the ViewMode menu
         setHighlightMode()

         # now click on a point on the plot, which will make it highlighted;
         # clicking on the plot returns a button press event, which creates
         # and handles an object of type gUpdateDataMessage  
       }

