-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathoutput_database.Rmd
executable file
·131 lines (87 loc) · 3.43 KB
/
output_database.Rmd
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
---
title: "Output metid database to mgf/msp for other tools"
author:
- name: Xiaotao Shen (https://www.shen-lab.org/)
date: "Created on 2020-07-02 and updated on `r Sys.Date()`"
output:
html_document:
df_print: paged
toc: no
pdf_document:
toc: no
vignette: >
%\VignetteIndexEntry{output_database}
%\VignettePackage{metid}
% \VignetteEngine{knitr::rmarkdown}
% \usepackage[utf8]{inputenc}
%\VignetteEncoding{UTF-8}
---
```{r, include=FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
out.width = "100%"
)
```
[`MassBank`](https://massbank.eu/), [`MoNA`](https://mona.fiehnlab.ucdavis.edu/) and some other public databases provide `msp` format database of metabolites. So you can use the functions in `metid` to output `metid` format database to `msp` format which can be used for `GNPS`, `MassBank` and `MoNA`.
# **MassBank**
## `msp` format
Just use the `write_msp_massbank()` function to output `metid` database to `msp` format for MassBank.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_msp_massbank(databasae = databasae, path = ".")
```
The arguments of `write_msp_massbank()` can be found here `write_msp_massbank()`.
## `mgf` format
Just use the `write_mgf_massbank()` function to output `metid` database to `mgf` format for MassBank.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_mgf_massbank(databasae = databasae, path = ".")
```
The arguments of `write_msp_massbank()` can be found here `write_msp_massbank()`.
# **MoNA**
## `msp` format
Just use the `write_msp_mona()` function to output `metid` database to `msp` format for mona.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_msp_mona(databasae = databasae, path = ".")
```
The arguments of `write_msp_mona()` can be found here `write_msp_mona()`.
## `mgf` format
Just use the `write_mgf_mona()` function to output `metid` database to `mgf` format for mona.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_mgf_mona(databasae = databasae, path = ".")
```
The arguments of `write_msp_mona()` can be found here `write_msp_mona()`.
# **GNPS**
## `msp` format
Just use the `write_msp_gnps()` function to output `metid` database to `msp` format for gnps.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_msp_gnps(databasae = databasae, path = ".")
```
The arguments of `write_msp_gnps()` can be found here `write_msp_gnps()`.
## `mgf` format
Just use the `write_mgf_gnps()` function to output `metid` database to `mgf` format for gnps.
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
library(metid)
```
```{r,eval = FALSE,warning=FALSE, message=FALSE,R.options="",cache=TRUE}
write_mgf_gnps(databasae = databasae, path = ".")
```
The arguments of `write_msp_gnps()` can be found here `write_msp_gnps()`.
# **Session information**
```{r,eval=TRUE,warning=FALSE, R.options="", message=FALSE, cache=TRUE}
sessionInfo()
```