# Plotting pairwise scatter plots of CAGE signal and calculating correlation between samples

### Description

Creates PNG file with scatter plots of CAGE signal for all pairs of selected samples and calculates the correlation between them.

### Usage

1 2 3 4 | ```
plotCorrelation(object, what = "CTSS", values = "raw",
samples = "all", method = "pearson",
tagCountThreshold = 1, applyThresholdBoth = FALSE,
plotSize = 800)
``` |

### Arguments

`object` |
A |

`what` |
Which level should be used for plotting and calculating correlation. Can be either |

`values` |
Specifies which values will be used for plotting and calculating correlation. Can be either |

`samples` |
Character vector of sample labels for which the scatter plots should be plotted and correlation calculated. Can be either |

`method` |
A character string indicating which correlation coefficient should be computed. Passed to |

`tagCountThreshold, applyThresholdBoth` |
Only TSSs with tag count |

`plotSize` |
Size of the individual comparison plot in pixels - the total size of the resulting png will be |

### Value

Creates PNG file named "Pairwise_tag_count_correlation.png" in the working directory. Returns a `matrix`

of pairwise correlations between selected samples.

### Author(s)

Vanja Haberle

### Examples

1 2 3 | ```
load(system.file("data", "exampleCAGEset.RData", package="CAGEr"))
plotCorrelation(object = exampleCAGEset)
``` |