adeverse / adegraphics

An S4 Lattice-Based Package for the Representation of Multivariate Data
https://adeverse.github.io/adegraphics/
9 stars 1 forks source link

implement the col parameter for subgraphs of plot graphs #8

Open thioulouse opened 6 years ago

thioulouse commented 6 years ago

data(meau) env <- meau$env sites <- meau$design$site envpca <- dudi.pca(env, scannf = FALSE) betsite <- bca(envpca, sites, scannf = FALSE) plot(betsite, row.col=1:6) plot(betsite, row.pellipse.col=1:6)

sdray commented 6 years ago

It works now (corrected by this commit) but we need to correct this last bug:

plot(betsite, col=1:6)
#or 
plot(betsite, col=TRUE)
aursiber commented 3 years ago

As the col argument is distributed to all subgraphs, the subgraphs row (s.class top-right) and eig (plotEig bottom-left) should be updated with the new colors (see below). Is this what we want?

Rplot

On the other hand, there is confusion between the col argument and the col subgraph. This is also the case for many other ade4 functions (plot.discrimin, plot.within, plot.dpcoa, plot.mcoa, plot.foucart, plot.mfa, plot.pta, scatter.dudi, scatter.coa, scatter.nipals, kplot.mfa, kplot.sepan, kplotsepan.coa, kplot.statis) which plot one or more subgraphs defined by an argument whose name begins by col (col, colB, collections).

sdray commented 3 years ago

In this example, it should apply only on the s.class plot and s.label (Classes). The argument should be probably treated separately before the call to sortparamADEgS and associated to the corresponding plot. For other functions, the behavior will be different