I'd like to be able to click on a point in a ggobi plot and perform a custom action. My first attempt (based on the results from this
) where my custom action is to print the row for the data frame I've identified:
gg <- ggobi(my.data.frame)
gSignalConnect(gg, "identify-point",
function(ggobi.plot, plot, id, dataset) {
print(dataset[,id+1])
}
}
Now when I identify a point by mousing over it, the custom action occurs. The problem is that identification is that while I'm dragging the mouse many points are selected. I'd like the selection to occur only when I click on the point. I then tried connecting to the "sticky-point-added" signal, which seems to only be triggered by a mouse click. However, I had to rewrite the function above to make things work:
gg <- ggobi(my.data.frame)
gSignalConnect(gg, "sticky-point-added",
function(ggobi.plot, id, ignore, dataset) {
print(dataset[,id+1])
}
}
Note that the callback function has a different set of arguments. I figured this out by trial and error, using the gSignalGetInfo() function.
My question:
(*) How can one definitively find out what arguments should be provided with the callback function and what they mean.
Thx.
Jeff