updatePoints             package:iSPlot             R Documentation

_U_p_d_a_t_e _p_o_i_n_t_s _o_n _a _p_l_o_t

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

     updatePoints replots only certain points on a plot, rather than 
     replotting the whole plot.  updatePoints is called when the type
     of  change performed on the dataframe was either modify or delete.

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

     updatePoints(plotIndex, Rname)

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

plotIndex: the index of the plot to be updated in viewList in viewEnv 

   Rname: the row name or index that changed - this may be a vector of
          length greater than or equal to one 

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

     Elizabeth Whalen

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

     'gUpdateViewMessage-class', 'replot'

_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 modify using the control window (by choosing the view mode and
         # then clicking on a plot)
         # by interacting with a plot when the view mode is color, these 
         # functions will be called automatically
         modify("USArrests", Rname=c("Massachusetts","Ohio"), 
                Cname=c("color","color"), data=c("red","green")) 
         # create an update view message and then dispatch it so the points
         # that have changed will be replot
         plMessage<-new("gUpdateViewMessage",type="modify",Rname=c("Massachusetts",
                        "Ohio"))
         handleMessage(plMessage,dataName="USArrests")
       }

