File: plot.Rmd

package info (click to toggle)
libpappsomspp 0.11.10-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 18,844 kB
  • sloc: cpp: 85,012; xml: 44,164; python: 668; sql: 186; sh: 33; makefile: 32
file content (38 lines) | stat: -rw-r--r-- 598 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
---
title: "plot DIA"
output: html_document
---


# DIA

```{r}
library(knitr)
library(ggplot2)
library(data.table)


setwd("~/developpement/git/pappsomspp/tests/dia")

df <- read.csv("../../build/tests/dia/mobility_dia_nano_10575_ms1/mobility.tsv", sep = "\t")


mz = df$m.z
tof = df$TOF.index
df$m.z = NULL
df$TOF.index = NULL
scans = colnames(df)

df = transpose(df)

rownames(df) = scans
df$scans = scans

dfc = df[,0:4]
dfc$scans = scans

long <- melt(setDT(dfc), variable.name = "ions")

ggplot(data=long, aes(x = scans, y=value, group=ions)) + geom_line(aes(col = ions))+  geom_point()

```