Movatterモバイル変換


[0]ホーム

URL:


Title:Analysis of Plant Pathogen Pathotype Complexities, Distributionsand Diversity
Version:4.0.0
Description:Analysis of plant pathogen pathotype survey data. Functions provided calculate distribution of susceptibilities, distribution of complexities with statistics, pathotype frequency distribution, as well as diversity indices for pathotypes. This package is meant to be a direct replacement for Herrmann, Löwer and Schachtel's (1999) <doi:10.1046/j.1365-3059.1999.00325.x> Habgood-Gilmour Spreadsheet, 'HaGiS', previously used for pathotype analysis.
License:MIT + file LICENSE
URL:https://github.com/openplantpathology/hagis,https://openplantpathology.github.io/hagis/
BugReports:https://github.com/openplantpathology/hagis/issues
Depends:R (≥ 3.4.0)
Imports:data.table, ggplot2, pander, stats, utils
Suggests:ape, dplyr, knitr, rmarkdown, roxyglobals, testthat, vdiffr,vegan
VignetteBuilder:knitr
Config/Needs/build:moodymudskipper/devtag
Config/roxyglobals/filename:globals.R
Config/roxyglobals/unique:FALSE
Encoding:UTF-8
Language:en-US
LazyData:true
RoxygenNote:7.3.2.9000
X-schema.org-applicationCategory:Tools
X-schema.org-isPartOf:https://openplantpathology.org
X-schema.org-keywords:plant-pathology, pathotype, pathogen-survey,virulence analysis, differential set, assessment scale
NeedsCompilation:no
Packaged:2025-07-26 03:58:08 UTC; adamsparks
Author:Austin G. McCoyORCID iD [aut, ccp], Zachary NoelORCID iD [aut, ccp], Adam H. SparksORCID iD [aut, cre], Martin ChilversORCID iD [aut, ths], Jari Oksanen [aut] (Contributed fix for the use of 'vegan' in betadiversity vignette.), Zhian N. KamvarORCID iD [ctb, rev], Michigan Soybean Promotion Committee [fnd, cph], Project GREEEN [fnd, cph], North Central Soybean Research Program [fnd, cph], Grains Research and Development CorporationROR ID [fnd, cph] (GRDC Project DAQ00186 and GRDC Project CUR2210-005OPX (AAGI-CU)), Michigan State UniversityROR ID [fnd, cph] (MSU AgBioResearch and MSU Extension), University of Southern QueenslandROR ID [fnd, cph], Curtin UniversityROR ID [fnd, cph]
Maintainer:Adam H. Sparks <adamhsparks@gmail.com>
Repository:CRAN
Date/Publication:2025-07-26 04:20:02 UTC

hagis: Analysis of Plant Pathogen Pathotype Complexities, Distributions and Diversity

Description

Analysis of plant pathogen pathotype survey data. Functions provided calculate distribution of susceptibilities, distribution of complexities with statistics, pathotype frequency distribution, as well as diversity indices for pathotypes. This package is meant to be a direct replacement for Herrmann, Löwer and Schachtel's (1999)doi:10.1046/j.1365-3059.1999.00325.x Habgood-Gilmour Spreadsheet, 'HaGiS', previously used for pathotype analysis.

Author(s)

Maintainer: Adam H. Sparksadamhsparks@gmail.com (ORCID)

Authors:

Other contributors:

See Also

Useful links:


Phytophthora sojae Survey Example Data

Description

Data from aPhytophthora sojae survey

Usage

data(P_sojae_survey)

Format

An object of classdata.table with 294 observations of 12variables

Isolate

P. sojae isolate identifier

Line

Soybean cultivar

Rps

Rps gene identifier

Total

Total number of plants inoculated

HR (1)

Number of plants that exhibit a hypersensitive responseafter inoculation

Lesion (2)

Number of plants that develop a lesion at inoculationsite

Lesion to cotyledon (3)

Number of plants that develop a lesion,which advances to the hypocotyl of the seedling after infection

Dead (4)

Number of dead plants that are observed after inoculation

total.susc

The total number of susceptible plants (Lesion+Lesion tocotyledon+Dead)

total.resis

The total number of resistant plants (equal to HRvalue)

Source

Data from an ongoing 2017Phytophthora sojae survey in Michigan,conducted by A. G. McCoyet al..

Examples

data(P_sojae_survey)P_sojae_survey

Plot hagis Complexities Objects

Description

Creates aggplot2 object of the frequency ofcomplexity (percent per complexity) or aggplot2 object of thedistribution (number per complexity) calculated bycalculate_complexities().

Usage

## S3 method for class 'hagis.complexities'autoplot(object, type, color = NULL, order = NULL, ...)

Arguments

object

ahagiscomplexities object generated bycalculate_complexities().Character.

type

a vector of values for which the bar plot is desired. Specifywhether to return a graph of the frequency of complexities as a percentage,"percentage", or as the count, "count".Character.

color

a named or hexadecimal color value to use for the bar color

order

sort the x-axis of the bar chart by ascending or descendingorder offrequency. Acceptsascending ordescending input values.Defaults tocomplexity value.Character.

...

passed to the chosengeom(s)

Value

Aggplot2 object

Examples

# Using the built-in data set, `P_sojae_survey`data(P_sojae_survey)# calculate susceptibilities with a 60 % cutoff valuecomplexities <- calculate_complexities(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")# Visualize the distribution (count or actual values)autoplot(complexities, type = "count")# Visualize the frequency (percentages)autoplot(complexities, type = "percentage")

Plot hagis Summary Objects

Description

Creates aggplot2 object of the gene summariescalculated bysummarize_gene()

Usage

## S3 method for class 'hagis.gene.summary'autoplot(object, type, color = NULL, order = NULL, ...)

Arguments

object

ahagis.gene.summary object generated bysummarize_gene().Character.

type

a vector of values for which the bar plot is desired. Specifywhether to return a graph of the percent pathogenic isolates,percentage,or as the count,count.Character.

color

a named or hexadecimal color value to use for the bar color

order

sort the x-axis of the bar chart by ascending or descendingorder ofN_virulent_isolates orpercent_pathogenic. Acceptsascendingordescending input values. Defaults togene name.Character.

...

passed to the chosengeom(s)

Value

Aggplot2 plot

Examples

# Using the built-in data set, `P_sojae_survey`data(P_sojae_survey)# calculate susceptibilities with a 60 % cutoff valuesusc <- summarize_gene(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")# Visualize the summary of genesautoplot(susc, type = "percentage")

Calculate Distribution of Complexities by Sample

Description

Calculate the distribution of susceptibilities by sample id.

Usage

calculate_complexities(x, cutoff, control, sample, gene, perc_susc)

Arguments

x

adata.frame containing the data.

cutoff

value for percent susceptible cutoff.Numeric.

control

value used to denote the susceptible control in thegenecolumn.Character.

sample

column providing the unique identification for each samplebeing tested.Character.

gene

column providing the gene(s) being tested.Character.

perc_susc

column providing the percent susceptible reactions.Character.

Value

An object of classhagis.complexities.

An object of classhagis.complexities is alist containing the followingcomponents

grouped_complexities

adata.table::data.table() object ofgrouped complexities

individual_complexities

adata.table::data.table() object ofindividual complexities

Examples

# Using the built-in data set, `P_sojae_survey`data(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuecomplexities <- calculate_complexities(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")complexitiessummary(complexities)

Calculate Diversities Indices

Description

Calculate five pathogen diversity indices.

Diversity indices include:

Usage

calculate_diversities(x, cutoff, control, sample, gene, perc_susc)

Arguments

x

adata.frame containing the data.

cutoff

value for percent susceptible cutoff.Numeric.

control

value used to denote the susceptible control in thegenecolumn.Character.

sample

column providing the unique identification for each samplebeing tested.Character.

gene

column providing the gene(s) being tested.Character.

perc_susc

column providing the percent susceptible reactions.Character.

Value

Ahagis.diversities object.

Ahagis.diversities object is alist containing:

Examples

# Using the built-in data set, P_sojae_surveydata(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuediversities <- calculate_diversities(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")diversities

Create Binary Data Matrix From Pathotype Data

Description

Creates a binary data matrix from pathotype data representingthe pathotype of each isolate. This binary data matrix can be used tovisualize beta-diversity of pathotypes usingvegan andape.

Usage

create_binary_matrix(x, cutoff, control, sample, gene, perc_susc)

Arguments

x

adata.frame containing the data.

cutoff

value for percent susceptible cutoff.Numeric.

control

value used to denote the susceptible control in thegenecolumn.Character.

sample

column providing the unique identification for each samplebeing tested.Character.

gene

column providing the gene(s) being tested.Character.

perc_susc

column providing the percent susceptible reactions.Character.

Value

a binary matrix of pathotype data

Examples

# Using the built-in data set, `P_sojae_survey`data(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuefinal_matrix <- create_binary_matrix(x = P_sojae_survey,                                    cutoff = 60,                                    control = "susceptible",                                    sample = "Isolate",                                    gene = "Rps",                                    perc_susc = "perc.susc")final_matrix

Custom Print for hagis Diversities Tables

Description

Print the frequency table of diversities from ahagis.diversities objectThe resulting object is apander table (a text object for Markdown)for ease of use in reporting and viewing in the console.

Usage

diversities_table(x, ...)

Arguments

x

ahagis.diversities object generated bycalculate_diversities()

...

other arguments passed topander::panderOptions()

Value

Apander::pandoc.table() object of diversities

See Also

calculate_diversities(),individual_pathotypes()

Examples

# Using the built-in data set, P_sojae_surveydata(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuediversities <- calculate_diversities(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")# print the diversities tablediversities_table(diversities)

Prints Individual Pathotypes for Each Sample

Description

Print an object from ahagis.diversities object with individual pathotypes,i.e. each sample's pathotype. The resulting object is apandertable (a text object for Markdown) for ease of use in reporting and viewingin the console.

Usage

individual_pathotypes(x, ...)

Arguments

x

ahagis.diversities object generated bycalculate_diversities()

...

other arguments passed topander::panderOptions()

Value

Apander::pander() object of individual pathotypes

See Also

calculate_diversities(),diversities_table()

Examples

# Using the built-in data set, P_sojae_surveydata(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuediversities <- calculate_diversities(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")# print the diversities tableindividual_pathotypes(diversities)

Objects exported from other packages

Description

These objects are imported from other packages. Follow the linksbelow to see their documentation.

ggplot2

autoplot


Phytophthora sojae Survey Example Metadata

Description

Metadata to accompany internal data from aPhytophthora sojae survey usedfor an example in the "Beta-diversity Analyses" vignette.

Usage

data(sample_meta)

Format

An object of classdata.frame with 21 observations of 2 variables

Sample

P. sojae sample identifier

Locale

US State where sample was collected, limited to Michigan

Source

Data from an ongoing 2017Phytophthora sojae survey in Michigan,conducted by A. G. McCoyet al..

Examples

data(sample_meta)sample_meta

Calculate and Summarize Distribution of Susceptibilities by Gene

Description

Calculate the distribution of susceptibilities by gene.

Usage

summarize_gene(x, cutoff, control, sample, gene, perc_susc)

Arguments

x

adata.frame containing the data.

cutoff

value for percent susceptible cutoff.Numeric.

control

value used to denote the susceptible control in thegenecolumn.Character.

sample

column providing the unique identification for each samplebeing tested.Character.

gene

column providing the gene(s) being tested.Character.

perc_susc

column providing the percent susceptible reactions.Character.

Value

ahagis.gene.summary object.

An object of classhagis.gene.summary is a
data.table::data.table()containing the following components columns

gene

the gene

N_virulent_isolates

the total number virulent isolates for agiven gene in thegene column

percent_pathogenic

the frequency with which a gene is pathogenic

Examples

# Using the built-in data set, `P_sojae_survey`data(P_sojae_survey)P_sojae_survey# calculate susceptibilities with a 60 % cutoff valuesusc <- summarize_gene(  x = P_sojae_survey,  cutoff = 60,  control = "susceptible",  sample = "Isolate",  gene = "Rps",  perc_susc = "perc.susc")susc

[8]ページ先頭

©2009-2025 Movatter.jp