updateDF {iSPlot}R Documentation

Determine values needed to initialize a gUpdateDataMessage object

Description

updateDF is called by the initialize method when creating an object of class, gUpdateDataMessage. updateDF determines the values of the slots for the gUpdateDataMessage object by calling either updateDFBysPlot or updateDFBySpread. The parameter, viewObj, determines which function is called: if the class of viewObj is sPlotView, then updateDFBysPlot is called and if the class of viewObj is spreadView, then updateDFBySpread is called. A list containing the slot values is returned.

Usage

updateDF(viewObj, where, ...)

Arguments

viewObj a view object, inherited from class genView
where where the data will change (for instance it could be a row name or index)
... extra parameters for the function, updateDFBySpread

Value

type the type of change, can be "add", "delete", "modify", or "reset"
mData the new data needed to update the data set
to which data set to update

Author(s)

Elizabeth Whalen

See Also

gUpdateDataMessage-class, updateDFBysPlot, updateDFBySpread

Examples

  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)  
    # now set the view mode
    setHighlightMode()

    # now click on a point on the plot and that will cause updateDF
    # to be called - you can tell it was called because the data and
    # thus, the plot will change  
  }

[Package iSPlot version 1.0.3 Index]