draw_canvas {drawProteins}R Documentation

Create ggplot2 object with protein chains from feature database

Description

draw_canvas uses the dataframe containing the protein features to creates the basic plot element by determining the length of the longest protein.

Usage

draw_canvas(data = data)

Arguments

data

Dataframe of one or more rows with the following column names: 'type', 'description', 'begin', 'end', 'length', 'accession', 'entryName', 'taxid', 'order'. Must contain a minimum of one "CHAIN" as data$type.

Value

A ggplot2 object either in the plot window or as an object.

Examples

# draws a blank canvas of the correct size
data("five_rel_data")
draw_canvas(five_rel_data)

# combines with draw_chains to plot and label chains.
data("five_rel_data")
p <- draw_canvas(five_rel_data)
p <- draw_chains(p, five_rel_data)
p


[Package drawProteins version 1.0.0 Index]