Learn R Programming

polySegratio (version 0.2-5)

plot.segRatio: Plot segregation ratios for either observed or simulated marker data

Description

Plots an object of S3 class segRatio

Usage

# S3 method for segRatio
plot(x, main =
deparse(substitute(x)), xlab="", xlab.segRatio = "Segregation ratio",
xlab.nobs = "Number of dominant markers",
xlab.miss = "Number of missing markers per individual",
NCLASS = 100, type = c("seg.ratio", "all","no","missing"), …)

# S3 method for simAutoMarkers plot(x, main = deparse(substitute(x)), xlab = "Segregation ratio",…)

# S3 method for simAutoCross plot(x, main = deparse(substitute(x)), xlab = "Segregation ratio", …)

Arguments

x

An object of class segRatio

xlab

label for x axis: not usually set

main

Title for plot

xlab.segRatio

x--axis label when plotting segregation proportions

xlab.nobs

x axis label when plotting no. of 1's

xlab.miss

x axis label when plotting number of missing individuals per marker

NCLASS

number of classes for histograms (Default: 100)

type

type of plot may be set to

  • seg.ratioHistogram of segregation proportions (Default)

  • noHistogram of the number of 1s

  • missingHistogram of the numbers of missing values per marker

  • allProduce all plots on one page

other parameters passed to plot function

Value

Used for its side-effects

Details

By default the histograms are produced of the segregation proportions. Other histograms that may be produced are numbers of observed dominant markers (recorded as a 1) and the number of individuals missing a particular marker.

See Also

segRatio, segregationRatios, sim.autoMarkers, sim.autoCross

Examples

Run this code
# NOT RUN {
## generate some autooctoploid data
a <- sim.autoMarkers(8,c(0.7,0.2,0.09,0.01))

## print markers and plot segratios
print(a)
plot(a$seg.ratios)  # plot the segregation ratios directly
plot(a)             # plot the simAutoMarkers object

## add some missing values and plot all histograms
plot(addMissing(a,0.2)$seg.ratios, type="all")
# }

Run the code above in your browser using DataLab