plot.ProbBin.FCS {rflowcyt} | R Documentation

## Plots a ProbBin.FCS object

### Description

A ProbBin.FCS object plot results in two histograms–one for the stimulated sample and one for the unstimulated sample.

### Usage

      plot.ProbBin.FCS(x, xlab=x$varname,
                   xlim=c(min(c(round(range(x$st.hist$breaks),1) + 1,
                      round(range(x$unst.hist$breaks),1) + 1)),
                      max(c(round(range(x$st.hist$breaks),1) + 1,
                      round(range(x$unst.hist$breaks),1) + 1))),

                  main="",
                  labels=FALSE,
                  freq=FALSE, plots.made=c("both", "stimulated", "unstimulated"), ...)

### Arguments

`x` | ProbBin.FCS object
`xlab` | Character string of the x-axis; default is the variable name
`xlim` | vector of length 2 denoting the minimum and the maximum value of the breakpoint values, x-axis; default is the minimum and the maximum of the breakpoints for both stimulated and unstimulated samples
`main` | character string of the title of the file (ie, individual id number)
`labels` | Boolean; if TRUE, then the number/precentage in each bin is printed on the histogram, otherwise it is not; default is FALS
`freq` | Boolean; if TRUE, then the histogram is in terms of counts; if FALSE, then the histogram is in terms of relative frequencies/precentages; if TRUE and the areas in plot are wrong is output as a warning.
`plots.made` | character string denoting which histogram plot should be displayed; default is "both"
`...` | plotting options such as 'ylab' and 'ylim' to pass to hist

### Value

Two histograms (one of the stimulated sample, and the other of the unstimulated sample) are displayed or only one histogram plot specified by the user will be displayed.

### Author(s)

A.J. Rossini & J.Y. Wan

### References

Mario Roederer, et al. "Probability Binning Comparison: A Metric for Quantitating Univariate Distribution Differences" Cytometry 45:37-46 (2001).

### See Also

`hist`, `ProbBin.FCS`

### Examples

    if (require(rfcdmin)){

    if (!( is.element("st.1829", objects()) & is.element("unst.1829",
    objects()) )){
    ## obtaining the FCS objects from VRC data
    data(VRCmin)
    }

    ## This only serves as an example.
    ## Gating/subsetting should precede this analysis
    IFN.gamma.1<-unst.1829@data[1:2000,4]
    IFN.gamma.2<-st.1829@data[1:2000,4]

    #Probability binning using the control dataset to determine the breaks
    PB1<-ProbBin.FCS(IFN.gamma.1, IFN.gamma.2, 200,
    varname=colnames(unst.1829@data)[4], PBspec="by.control",MY.DEBUG=FALSE)

    ## Probability Binning using the combined dataset (control and stimulated)
    ## to determing the breaks
    PB2<-ProbBin.FCS(IFN.gamma.1, IFN.gamma.2, 200,
    varname=colnames(unst.1829@data)[4], PBspec="combined",MY.DEBUG=FALSE)

    if (interactive()){
    par(mfrow=c(2,2))
    ## plots both plots
    plot(PB1, ylim=c(0,500),main="Prob Binning using the Control dataset")

    ## plots only the unstimulated
    plot(PB2, main="Prob Binning using the Combined Dataset", plots.made="unstimulated")

    ## plots only the stimulated
    plot(PB2, main="Prob Binning using the Combined Dataset", plots.made="stimulated")
    }

    }

[Package rflowcyt version 1.6.0 Index]