Coerce an object to a class

coerce(from, to, strict = TRUE)

Arguments

from, to, strict

See coerce for details.

Value

Modified object of new desired class.

Examples

showMethods("coerce")
#> Function: coerce (package methods) #> from="AnnotatedDataFrame", to="data.frame" #> from="ANY", to="array" #> from="ANY", to="AsIs" #> from="ANY", to="call" #> from="ANY", to="character" #> from="ANY", to="CharacterList" #> from="ANY", to="complex" #> from="ANY", to="ComplexList" #> from="ANY", to="CompressedCharacterList" #> from="ANY", to="CompressedComplexList" #> from="ANY", to="CompressedDataFrameList" #> from="ANY", to="CompressedDFrameList" #> from="ANY", to="CompressedFactorList" #> from="ANY", to="CompressedIntegerList" #> from="ANY", to="CompressedList" #> from="ANY", to="CompressedLogicalList" #> from="ANY", to="CompressedNumericList" #> from="ANY", to="CompressedRawList" #> from="ANY", to="CompressedRleList" #> from="ANY", to="CompressedSplitDataFrameList" #> from="ANY", to="CompressedSplitDFrameList" #> from="ANY", to="DataFrame" #> from="ANY", to="DataFrame_OR_NULL" #> from="ANY", to="DataFrameList" #> from="ANY", to="DFrame" #> from="ANY", to="DFrameList" #> from="ANY", to="double" #> from="ANY", to="environment" #> from="ANY", to="expression" #> from="ANY", to="FactorList" #> from="ANY", to="FilterRules" #> from="ANY", to="function" #> from="ANY", to="integer" #> from="ANY", to="IntegerList" #> from="ANY", to="IntegerRanges" #> from="ANY", to="IPos" #> from="ANY", to="IPosRanges" #> from="ANY", to="list" #> from="ANY", to="List" #> from="ANY", to="logical" #> from="ANY", to="LogicalList" #> from="ANY", to="matrix" #> from="ANY", to="name" #> from="ANY", to="NULL" #> from="ANY", to="numeric" #> from="ANY", to="NumericList" #> from="ANY", to="RawList" #> from="ANY", to="Rle" #> from="ANY", to="RleList" #> from="ANY", to="S3" #> from="ANY", to="S4" #> from="ANY", to="SimpleCharacterList" #> from="ANY", to="SimpleComplexList" #> from="ANY", to="SimpleDataFrameList" #> from="ANY", to="SimpleDFrameList" #> from="ANY", to="SimpleFactorList" #> from="ANY", to="SimpleIntegerList" #> from="ANY", to="SimpleList" #> from="ANY", to="SimpleLogicalList" #> from="ANY", to="SimpleNumericList" #> from="ANY", to="SimpleRawList" #> from="ANY", to="SimpleRleList" #> from="ANY", to="SimpleSplitDataFrameList" #> from="ANY", to="SimpleSplitDFrameList" #> from="ANY", to="SplitDataFrameList" #> from="ANY", to="SplitDFrameList" #> from="ANY", to="StitchedIPos" #> from="ANY", to="ts" #> from="ANY", to="UnstitchedIPos" #> from="ANY", to="vector" #> from="AsIs", to="DFrame" #> from="AtomicList", to="RleViews" #> from="character", to="IRanges" #> from="character", to="LLint" #> from="character", to="signature" #> from="character", to="SuperClassMethod" #> from="CompressedAtomicList", to="list" #> from="CompressedIRangesList", to="CompressedNormalIRangesList" #> from="CompressedRleList", to="CompressedIRangesList" #> from="data.frame", to="AnnotatedDataFrame" #> from="data.frame", to="DFrame" #> from="data.table", to="DFrame" #> from="DataFrame", to="Grouping" #> from="DataFrame", to="SplitDFrameList" #> from="DataFrame", to="TransposedDataFrame" #> from="DataFrameList", to="DFrame" #> from="derivedDefaultMethod", to="function" #> from="DFrame", to="DataFrame" #> from="eSet", to="ExpressionSet" #> from="eSet", to="MultiSet" #> from="ExpressionSet", to="data.frame" #> from="exprSet", to="ExpressionSet" #> from="factor", to="Factor" #> from="factor", to="IRanges" #> from="factor", to="ManyToOneGrouping" #> from="FactorList", to="Grouping" #> from="function", to="classGeneratorFunction" #> from="function", to="FilterClosure" #> from="function", to="OptionalFunction" #> from="groupGenericFunction", to="genericFunction" #> from="grouping", to="Grouping" #> from="grouping", to="ManyToOneGrouping" #> from="Hits", to="CompressedIntegerList" #> from="Hits", to="DFrame" #> from="Hits", to="Grouping" #> from="Hits", to="IntegerList" #> from="Hits", to="List" #> from="Hits", to="SelfHits" #> from="Hits", to="SortedByQueryHits" #> from="Hits", to="SortedByQuerySelfHits" #> from="HitsList", to="SortedByQueryHitsList" #> from="integer", to="IRanges" #> from="integer", to="List" #> from="integer", to="LLint" #> from="integer", to="NormalIRanges" #> from="IntegerRanges", to="CompressedIPosList" #> from="IntegerRanges", to="CompressedIRangesList" #> from="IntegerRanges", to="IPos" #> from="IntegerRanges", to="IPosList" #> from="IntegerRanges", to="IRanges" #> from="IntegerRanges", to="NCList" #> from="IntegerRanges", to="PartitioningByEnd" #> from="IntegerRanges", to="PartitioningByWidth" #> from="IntegerRanges", to="StitchedIPos" #> from="IntegerRanges", to="UnstitchedIPos" #> from="IntegerRangesList", to="CompressedNormalIRangesList" #> from="IntegerRangesList", to="NCLists" #> from="IntegerRangesList", to="NormalIRangesList" #> from="IntegerRangesList", to="RangedSelection" #> from="IntegerRangesList", to="SimpleIRangesList" #> from="IntegerRangesList", to="SimpleNormalIRangesList" #> from="IPosRanges", to="CompressedIntegerList" #> from="IPosRanges", to="IntegerList" #> from="IRanges", to="IPosList" #> from="IRanges", to="NormalIRanges" #> from="list_OR_List", to="Pairs" #> from="list", to="CharacterList" #> from="list", to="ComplexList" #> from="list", to="CompressedIRangesList" #> from="List", to="CompressedIRangesList" #> from="list", to="DFrame" #> from="list", to="DFrameList" #> from="list", to="FactorList" #> from="list", to="IntegerList" #> from="list", to="IRangesList" #> from="List", to="IRangesList" #> from="list", to="List" #> from="List", to="list" #> from="list", to="LogicalList" #> from="list", to="NumericList" #> from="list", to="RawList" #> from="list", to="RleList" #> from="list", to="SimpleIRangesList" #> from="List", to="SimpleIRangesList" #> from="list", to="SplitDFrameList" #> from="list", to="TransposedDataFrame" #> from="logical", to="IRanges" #> from="logical", to="LLint" #> from="logical", to="NormalIRanges" #> from="LogicalList", to="CompressedNormalIRangesList" #> from="LogicalList", to="NormalIRangesList" #> from="LogicalList", to="SimpleNormalIRangesList" #> from="ManyToOneGrouping", to="factor" #> from="MaskCollection", to="NormalIRanges" #> from="NCLists", to="CompressedIRangesList" #> from="NCLists", to="IRangesList" #> from="NormalIRangesList", to="CompressedNormalIRangesList" #> from="NULL", to="DFrame" #> from="NULL", to="OptionalFunction" #> from="NULL", to="optionalMethod" #> from="numeric", to="IRanges" #> from="numeric", to="LLint" #> from="numeric", to="NormalIRanges" #> from="oldClass", to="S3" #> from="Pairs", to="DFrame" #> from="PartitioningByEnd", to="PartitioningMap" #> from="phenoData", to="AnnotatedDataFrame" #> from="Rle", to="character" #> from="Rle", to="complex" #> from="Rle", to="factor" #> from="Rle", to="integer" #> from="Rle", to="IRanges" #> from="Rle", to="list" #> from="Rle", to="logical" #> from="Rle", to="NormalIRanges" #> from="Rle", to="numeric" #> from="Rle", to="raw" #> from="Rle", to="vector" #> from="RleList", to="CompressedNormalIRangesList" #> from="RleList", to="NormalIRangesList" #> from="RleList", to="SimpleNormalIRangesList" #> from="RleViewsList", to="IRangesList" #> from="RleViewsList", to="SimpleIRangesList" #> from="SelfHits", to="SortedByQuerySelfHits" #> from="SimpleIntegerRangesList", to="SimpleIRangesList" #> from="SimpleIRangesList", to="SimpleNormalIRangesList" #> from="SimpleList", to="CharacterList" #> from="SimpleList", to="ComplexList" #> from="SimpleList", to="DataFrame" #> from="SimpleList", to="DFrame" #> from="SimpleList", to="DFrameList" #> from="SimpleList", to="FactorList" #> from="SimpleList", to="FilterRules" #> from="SimpleList", to="IntegerList" #> from="SimpleList", to="LogicalList" #> from="SimpleList", to="NumericList" #> from="SimpleList", to="RawList" #> from="SimpleList", to="RleList" #> from="SimpleList", to="SimpleIRangesList" #> from="SimpleList", to="SplitDFrameList" #> from="SortedByQueryHits", to="CompressedIntegerList" #> from="SortedByQueryHits", to="IntegerList" #> from="SortedByQueryHits", to="IntegerRanges" #> from="SortedByQueryHits", to="IRanges" #> from="SortedByQueryHits", to="List" #> from="SortedByQueryHits", to="Partitioning" #> from="SortedByQueryHits", to="PartitioningByEnd" #> from="SortedByQueryHits", to="SortedByQuerySelfHits" #> from="SortedByQueryHitsList", to="HitsList" #> from="SplitDataFrameList", to="DFrame" #> from="standardGeneric", to="FilterClosure" #> from="StitchedIPos", to="UnstitchedIPos" #> from="table", to="DFrame" #> from="TransposedDataFrame", to="DataFrame" #> from="UnstitchedIPos", to="StitchedIPos" #> from="vector_OR_Vector", to="Factor" #> from="Vector", to="character" #> from="Vector", to="complex" #> from="Vector", to="data.frame" #> from="Vector", to="DFrame" #> from="Vector", to="factor" #> from="vector", to="Grouping" #> from="Vector", to="integer" #> from="Vector", to="logical" #> from="vector", to="ManyToManyGrouping" #> from="vector", to="ManyToOneGrouping" #> from="Vector", to="numeric" #> from="Vector", to="raw" #> from="Vector", to="vector" #> from="Vector", to="Views" #> from="Versions", to="character" #> from="Views", to="IntegerRanges" #> from="Views", to="IRanges" #> from="Views", to="NormalIRanges" #> from="xtabs", to="DFrame" #>