Skip to content

granovagg.contr doesn't let users set x axis labels #68

Description

@briandk

Again, we can discuss this, but the default behavior is contained within a function that gets called by an apply call. The reason for that behavior is so we can automate and standardize pasting contrast names into the x-axis label:

  ComposeContrastPlot <- function(plot.data, index) {    
    p <- ggplot()
    p <- p + MeanResponse(plot.data[[index]]$raw.data$y.values)
    p <- p + JitteredResponsesByContrast(plot.data[[index]]$raw.data)
    p <- p + EffectsOfContrasts(plot.data[[index]]$summary.data)
    p <- p + ConnectEffectMeans(plot.data[[index]]$summary.data)
    p <- p + Theme(plot.theme)
    p <- p + ContrastPlotTitle(ctr, index)
    p <- p + ContrastPlotXLabel(ctr, index)
    p <- p + ContrastPlotYLabel()

    return(p)
  }

and

  ContrastPlotXLabel <- function(ctr, index) {
    return(
        xlab(paste(GetContrastName(ctr$contrast.matrix, index)))
    )
  }

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions