Skip to content

Releases: epurdom/clusterExperiment

v2.1.5

28 Jun 11:16
Compare
Choose a tag to compare

Changes in version 2.1.5 ( Release date: 2018-06-28)

Changes:

  • Add functionality to getBestFeatures to allow edgeR for DE, as well as weights used with edgeR for zinbwave compatability. As part of this change:
    • Removed isCount argument and replaced with more fine-grained DEMethod argument in getBestFeatures, mergeClusters; or mergeDEMethod in RSEC.
    • Change to class definition: added slot merge_demethod to keep track of the DE method used in merging
  • Change function names (old function name is now depricated):
    • combineMany -> makeConsensus
    • removeUnclustered -> removeUnassigned
  • Arguments to functions changed:
    • combineProportion -> consensusProportion in RSEC
    • combineMinSize -> consensusMinSize in RSEC
    • sampleData -> colData to match SummarizedExperiment syntax (in many plotting functions).
      • alignSampleData -> alignColData in plotHeatmap
    • ignoreUnassignedVar -> filterIgnoresUnassigned in mergeClusters (and other functions) for clarity.
      • removeNegative -> removeUnassigned in getBestFeatures for uniformity
      • Removed largeDataset option to subsampleClustering because no longer provides advantage.
      • nBlank -> nBlankFeatures in makeBlankData to allow for samples
  • Created functions:
    • primaryClusterLabel and primaryClusterType
    • getReducedData
    • assignUnassigned: assigns unassigned samples to nearest cluster
      • renameClusters and recolorClusters: assign new names/colors to clusters within a particular clustering
    • clusterMatrixColors: wrapper to convertClusterLegend to return matrix like clusterMatrix only with colors in place of the internal cluster ids (like existing clusterMatrixNamed)
      • plotClustersTable for plotting a heatmap showing the results of tableClusters
      • subsetByCluster for subsetting CE object to only those samples in a particular cluster(s) of a clustering.
      • plotFeatureScatter for a scatter plot of 2+ features (genes) colored by cluster
      • addToColData and colDataClusters adding clustering information to colData of object. addToColData returns object with colData augmented, while colDataClusters just returns the DataFrame with clusterings added.
      • updateObject to update historical object created from previous versions to the current class definitions.
  • Added arguments:
    • whichAssay to all functions to allow the user to select the assay on which the operations will be performed.
    • stopOnErrors to RSEC
    • nColLegend to plotReducedDims
    • subsample and sequential to RSEC to allow for opting out of those options (but default is TRUE unlike clusterMany)
    • nBlankSamples and groupsOfSamples to makeBlankData to allow for separating samples (columns)
    • add and location to plotClusterLegend
  • makeBlankData will now allow for making blank columns to separate groups of samples.
  • plotDendrogram now allows for plotting of colData (previously sampleData) like plotHeatmap or plotClusters
  • clusterMany now allows user-defined ClusterFunction objects to argument clusterFunction.
  • Removed restriction in plotClustersWorkflow that only clusterType="clusterMany" allowed.
  • Allow getClusterManyParams to search old clusterMany runs as well.
  • Added table method to plotHeatmap (for plotting heatmap of results of table function)
  • Added error catch if try to give argument whichCluster to mergeCluster.
  • Added error catch if give param whichClusters to functions that only take whichCluster (singular) as an argument
  • plotFeatureBoxplot now returns (invisibly) the colors and clusterIds along with the boxplot information.

Bugs:

  • Add check for merge_nodeMerge table that mergeClusterId column can't be NA for entries where isMerged=TRUE
  • Fix internal .makeIntegerClusters so that if given values 1:K for input clustering will retain these same values (Issue #227)
  • mergeClusters now returned object saves the merge information (and deletes old info and updates clusterType/clusterLabel of existing merge clusters), even if mergeMethod="none".
  • Fix removeClusterings so doesn't loose merge info unless deleting relevant clusterings.

v. 2.1.2

17 May 09:49
Compare
Choose a tag to compare

Changes in version 2.1.2 ( Release date: 2018-05-17)

2.1.1 and 2.1.2 are purely bug fixes found in 2.0.0 after Bioconductor release 3.7. The following are the list of bug fixes.

Bugs:

  • Fix so that estimates of the proportion non-null in mergeClusters are always positive.
  • Fix so that calculation of filter with ignoreUnassignedVar doesn't delete existing base filter of same type.
  • Fix plotClustersWorkflow where wrong cluster was grabbed to plot.
  • Fix bug in plotDendrogram where colors of clusters plotted with could be subsumbed by color of previous clustering. (git Issue #220 )
  • Fixed error introduced in 2.0.0 where arguments to mergeCutoff and mergeLogFCcutoff where passed instead to dendroNDims.

v.1.3.6

23 Oct 22:59
Compare
Choose a tag to compare

Changes:

  • MAJOR CHANGE TO DEFINITION OF CLASS: Added slots to ClusterExperiment object so that the object keeps the information about the merging, and added corresponding helper functions (see documentation). This means previous versions made of a ClusterExperiment object will no longer be valid objects! Old, saved objects from previous versions must be manually adapted to have these slots (with NULL or NA values as appropriate).
  • Add function plotClustersWorkflow, see documentation
  • Add function plotDimReduce for plotting low-dim pca with points labeled by cluster.
  • Add function plotContrastHeatmap to plot the significant genes that are result of getBestFeatures
  • getBestFeatures: can now be run on result of mergeClusters without having to call makeDendrogram again for the merged clusters.
  • Change argument to plotClusters and plotBarplot from clusters to object
  • makeDendrogram: default in is now dimReduce="mad" to avoid accidentally calling it with dimReduce="none" (previous default), which can kill interactive R sessions.
  • Changes to plotHeatmap:
    • default in plotHeatmap to clusterSamplesData="dendrogramValue".
    • Changed handling of clusterSamplesData argument in plotHeatmap so that if argument equals dendrogramValue or primaryCluster and gives bad results / errors, will give warning and change argument appropriately.
    • Added arguments to plotHeatmap allowing more user control regarding making blank lines for when have gene groupings.
  • mergeClusters now aligns the colors from mergeClusters and combineMany internally.
  • mergeClusters now suppresses warnings created by the estimation of the percentage non-null unless showWarnings=TRUE.
  • plotDendrogram:
    • has new argument clusterLabelAngle allowing user to change the angle of the clusterLabel printed on top (when plot is of type "colorblock")
    • argument labelType has been changed to plotType

Bugs:

  • Arguments passed to mergeClusters, ClusterExperiment version, via the ... command will now go first to the mergeClusters matrix version and then onto the plotting, as stated in documentation (plotting arguments were being ignored on the clusterExperiment version of the function).

v. 1.3.4

23 Oct 22:58
Compare
Choose a tag to compare

Changes:

  • Add argument clusterLabels to plotClusters to allow user to set clusterLabels without changing the object.
  • Added data object of run of RSEC. Changed lazyLoad to false because loading this object on installation was creating errors.
  • Updated vignette to more completely cover RSEC.
  • Change default clusterFunction argument to RSEC to be "hierarchical01" rather than all 01 methods (previous default). This reduces load of making simple call.
  • Updated validity checks to reduce memory load, and dropped validObject calls.
  • Added function getClusterManyParams to parse the parameter values in the clusterLabels from clusterMany
  • Removed old dependency on diagram (from previous vignette, no longer needed)

Bugs:

  • Fixed error in subsetting of clusterExperiment object when dendrogram is attached (previously didn't reset dendro_outbranch to NA)

v 1.3.3

07 Sep 10:21
Compare
Choose a tag to compare

Changes:

  • Bug fix in clusterContrasts -- missing match.arg option for outputType argument

v1.3.2

05 Jul 23:56
Compare
Choose a tag to compare

Changes:

  • Default for top.can in seqCluster are changed to be top.can=5.
  • makeDendrogram now has the default argument ignoreUnassignedVar=TRUE like in RSEC
  • add ClusterFunction class and update all functions to work on this. All built in cluster functions are now given ClusterFunction Objects, so all built in clustering functions can now work for either subsampleClustering or mainClustering. This will also make it easier for a user to define their own ClusterFunction object and have it be used by functions like clusterSingle. This is a major change in how some of the underlying functions work, but should not impact common functions like clusterMany and RSEC. Some of the more notable changes in the arguments for programmers are:
    • clusterD and clusterDArgs have been changed to mainClustering and mainClusterArgs. This change was made to make these arguments more clear as to their role in the clustering workflow (and because the clusterD refered to clustering a dissimilarity but it has clustered either x or D for many versions now. )
    • seqCluster and clusterSingle no longer take the argument clusterFunction. clusterFunction must be given via mainClusterArgs and subsampleArgs to be passed to mainClustering or subsamplingCluster, respectively. Now only the upper-level function clusterMany takes clusterFunction directly as an argument.
    • mainClustering (previously clusterD) and subsampleClustering no longer take k nor alpha as a direct argument. These arguments, like all arguments used directly by the cluster function, now need to be passed to the clustering function in a list via clusterArgs.
    • The list of available built-in clustering routines provided by the package can now be accessed via listBuiltInFunctions(). The functions that are used for these functions are now available to the user via their ClusterFunction object that the user can access with the function getBuiltInFunction. (see ?listBuiltInFunctions)
  • hiearchical01 clustering now has a different default, namely to apply as.dist to the input diss in order to get a dist object, rather than dist(1-diss) which was previously the default for historical reasons. This is controlled by argument whichHierDist, and can be set to the previous version by passing whichHierDist="dist" to the clusterArgs argument in either subsampleArgs or mainClusterArgs, depending on where hierarchical01 is being used.
  • Spectral clustering is now available ("spectral") via the specc function of kernlab.
  • clusterSingle now only returns the dissimilarity matrix in the coClustering slot if subsample=TRUE in the call. Furthermore, for the resulting dissimilarity to replace an existing coClustering slot value, the user must request it by setting replaceCoClustering=TRUE in the call to clusterSingle.
  • Removed default value for argument proportion in combineMany. The previous default was proportion=1 but didn't match most common use cases and was accidentally called by upper functions like RSEC.
  • If the clusterFunction argument is not given to subsampleArgs by the user explicitly, and the clusterFunction of mainClusterArgs is appropriate, it will be used for subsampleClustering; if the clusterFunction in mainClusterArgs is not appropriate (e.g. subsampleClustering needs a type K because sequential=TRUE), then the default for the subsampleClustering will be 'pam'. This changes the previous behavior of subsampleClustering where the default was 'pam' in all cases where not explicitly given by the user. This change should have no impact on RSEC: since the clusterFunction for the mainClustering terms is a '01' type in RSEC and the subsampleClustering has to be type 'K' when sequential=TRUE, it will revert to the default "pam" as before.

Bugs:

  • Fixed error so where if clusterSingle was called on existing clusterExperiment object it would overwrite the information of the existing clusterExperiment object.
  • Fixed RSEC so now if rerun on existing clusterExperiment object, it will grab defaults from the matrix version (previously defaults were those of the underlying function, which were not always the same, e.g. combineProportion default was previously 1)
  • Fixed clusterMany so now it explicitly sets dimReduce="none" in call to clusterSingle. Before, might have been calling all of the dimReduce defaults (i.e. all of them!).
  • Fixed so gives error if whichClusters in plotBarplot doesn't match anything.

v.1.3.1

14 Jun 23:32
Compare
Choose a tag to compare

Changes in version 1.3.1 ( Release date: 2017-06-14 )

Changes:

  • change how plotHeatmap handles visualizeData argument, so not required to have same number of genes as original, only same number of samples.
  • Now if color of vectors given in clusterLegend does not have names, plotHeatmap will give them names matching the variable so that they will be used by aheatmap (previously would have left all colors white because do not have matching names).
  • Large changes to how dendrograms are plotted by plotDendrogram and mergeClusters. This includes the ability to see the before and after clusterings along side the mergeClusters result, as well as a new slot added to the clusterExperiment class (dendro_outbranch). The names of several arguments to mergeClusters and plotDendrogram were changed for clarity:
    • leaves is now leafType in plotDendrogram.
    • plotType is now plotInfo in mergeClusters
    • doPlot is now plot in mergeClusters
    • leafType is now an option for mergeClusters as well.
    • Now when plotInfo (previously plotType) is set to none, the plot is still drawn, but just no information about the merging is added to the plot. To not plot the dendrogram at all, set plot=FALSE.
    • The option labelType in either plotDendrogram or mergeClusters controls whether names (name) or rectangular color blocks corresponding to the cluster (colorblock) are put at the tips of the dendrogram to label the clusters/samples.
  • added dendroClusterIndex that behaves similarly to primaryClusterIndex
  • added ability to give dendro as charater option to whichClusters argument
  • added transformation<- to be able to assign manually the transformation slot
  • Move MAST into 'suggests' pacakge so that not need R 3.4 to run the package.
  • Change calculation of PCA dimensionality reduction to use svds from RSpectra package to improve speed

Bugs:

  • Fixed bug in RSEC where combineProportion argument was being ignored (set to 1)
  • Fixed bug in definition of transform so that extends existing generic rather than masking it.

v1.3.0

25 May 22:17
Compare
Choose a tag to compare

Changes:

  • plotHeatmap accepts data.frame or ExpressionSet objects for the data argument (calls data.matrix or exprs on object and sends to matrix version)
  • Added plotBarplot to plot a barplot for 1 cluster or comparison of 2 clusters along with tests.
  • Added whichClusters argument to clusterMatrix to return only clusters corresponding to certain clusters. Mainly relevant for using arguments like workflow that are used by other commands (otherwise could just index the complete matrix manually...)

Bug fixes:

  • plotHeatmap now goes through the clusterLegend input and removes levels that do not exist in the sampleData; this was causing incorrect coloring when the clusterLegend had more (or less) levels that it assigned color to than the sampleData did (e.g. if sampleData was a subset of larger dataset upon which the original colors were assigned.) NOTE: that this now has the effect of NOT plotting all values in the clusterLegend if they are not represented in the data, thus changing the previous behavior of plotHeatmap legend.
  • fixed bug in how plotHeatmap checked that the dimensions of user-supplied dendrogram match that of data (matrix version).
  • fixed convertClusterLegend so when output is matrixNames or matrixColors, the resulting matrix has the colnames equal to cluster labels, like clusterMatrix.

1.2.0

07 Apr 18:21
Compare
Choose a tag to compare

Changes:

  • RSEC now has option rerunClusterMany, which if FALSE will not rerun the clusterMany step if RSEC is called on an existing clusterExperiment object (assuming of course, clusterMany has been run already on the object)
  • setBreaks now has option makeSymmetric to force symmetric breaks around zero when using the quantile option.
  • setBreaks now has a default for breaks (i.e. for minimal use, the user doesn't have to give the argument, just the data) in which case setBreaks will automatically find equal-spaced breaks of length 52 filling the range of data compatible with aheatmap. The order of the arguments data and breaks has been switched, however, to better accomodate this usage.
  • plotClusters can now handle NA values in the colData
  • plotClusters for clusterExperiment object now allows for setting sampleData=TRUE to indicate the plotting all of the sampleData in the colData slot.
  • nPCADims now allows values between 0,1 to allow for keeping proportion of variance explained.
  • addClusters now allows for argument clusterLabel to assign a clusterLabel when the added cluster is a vector (if matrix, then clusterLabel is just the column names of the matrix of cluster assignments)

Bug fixes:

  • fixed bug in clusterExperiment subsetting to deal with orderSamples correctly.
  • fixed bug in mergeClusters unable to plot when too big of edge lengths (same as plotDendrogram)
  • fixed bug in subsetting, where unable to subset samples by character
  • fixed bug in removeClusters so that correctly updates dendro_index and primary_index slots after cluster removed.

v1.1.1

21 Oct 00:52
Compare
Choose a tag to compare

Changes:

  • Inverted definition of contrast for one-versus-all so now is X-ave(all but X); this means logFC positive -> cluster X greater than average of rest

Bug fixes:

  • add check in clusterMany that non-zero dimensions
  • changed 'warning' to 'note' in combineMany when no clusters specified.
  • fixed bug in plotDendrogram unable to plot when makeDendrogram used dimReduce="mad"
  • fixed bug in clusterMany where beta set to NA if clusteringFunction is type K. Added check that beta cannot be NA.
  • Added check that alpha and beta in (0,1)