Stat.getRBoxplotString C# (CSharp) Méthode

getRBoxplotString() private méthode

private getRBoxplotString ( GraphROptions gro, string fileName, Sides side ) : string
gro GraphROptions
fileName string
side Sides
Résultat string
    private string getRBoxplotString(GraphROptions gro, string fileName, Sides side)
    {
        string allData = convertDataToR(gro, side);

        string ylabStr = "";
        if(side == Sides.RIGHT) {
            if(CurrentGraphData.LabelRight != "")
                ylabStr = ", ylab='" + Util.RemoveTilde(CurrentGraphData.LabelRight) + "'";
        }
        else { //ALL or LEFT
            if(CurrentGraphData.LabelLeft != "")
                ylabStr = ", ylab='" + Util.RemoveTilde(CurrentGraphData.LabelLeft) + "'";
        }

        string rG = //rGraphString
            "boxplot(as.data.frame(data), lwd="+ gro.LineWidth +", las=2, xlab=''" + ylabStr + ")\n" +
            "axis(1, 1:length(colnames(data)), colnames(data), las=2)\n"; //axis separated from boxplot because if data hsa one col, names are not displayed

        //have an unique title for both graphs
        string titStr = getTitle("Boxplot","");
        if(hasTwoAxis()) {
               if(side==Sides.RIGHT)
                rG += "par(mfrow=c(1,1), new=TRUE)\n" +
                    "plot(-1, axes=FALSE, type='n', xlab='', ylab='')\n" +
                    titStr +
                    "par(mfrow=c(1,1), new=FALSE)\n";
        } else
            rG += titStr;

        return allData + rG;
    }