Skip to content

Commit

Permalink
Change readme, news, and version (to 1.0.3)
Browse files Browse the repository at this point in the history
  • Loading branch information
stefpeschel committed Jun 26, 2022
1 parent 21c6b9a commit 65a4790
Show file tree
Hide file tree
Showing 11 changed files with 245 additions and 184 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: NetCoMi
Type: Package
Title: Network Construction and Comparison for Microbiome Data
Version: 1.0.2.9001
Version: 1.0.3
Author: Stefanie Peschel [aut, cre]
Maintainer: Stefanie Peschel <[email protected]>
Description: NetCoMi offers functions for constructing, analyzing, and comparing
Expand Down
43 changes: 43 additions & 0 deletions NEWS.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,49 @@
output: github_document
---

## NetCoMi 1.0.3 <img src="man/figures/NetCoMi_logo_800x400_300dpi.png" align="right" width="200" />

This is a minor release with some bug fixes and changes in the documentation.

### Bug fixes

* `netConstruct()` threw an error if the data had no row and/or column names,
which is fixed.

* An edge list is added to the output of `netConstruct()` (issue [#41](https://github.com/stefpeschel/NetCoMi/issues/41)). See the
help page for details.

* `SPRING`'s fast version of latent correlation computation (implemented in
[mixedCCA](https://github.com/irinagain/mixedCCA)) is currently not available
due to deprecation of the R package `chebpol`. The issue is fixed by setting
the `netConstruct()` parameter `measurePar$Rmethod` internally to "original" if
SPRING is used for association estimation.

* In `plot.microNetProps()`: The `xpd` parameter is changed to `NA` so that
plotting outside the plot region is possible (useful for legends or additional
text).

* Labels in the network plot can now be suppressed by setting `labels = FALSE`
(issue [#43](https://github.com/stefpeschel/NetCoMi/issues/43))

* The `netCompare()` function threw an error if one of the permutation networks
was empty, i.e. had no edges with weight different from zero (issue [#38](https://github.com/stefpeschel/NetCoMi/issues/38)),
which is now fixed.

* Fix issues [#29](https://github.com/stefpeschel/NetCoMi/issues/29) and [#40](https://github.com/stefpeschel/NetCoMi/issues/40), where permutation tests
did not terminate for small sample sizes.
Now, if the possible number of permutations (resulting from the sample
size) is smaller than that defined by the user, the function stops and returns
an error.

* Fix a bug in `diffnet()` (issue
[#51](https://github.com/stefpeschel/NetCoMi/issues/51)), where colors in
differential networks could not be changed.

* `diffnet()` threw an error if the `netConstruct()` argument `jointPrepro` was
set to `TRUE`.


## NetCoMi 1.0.2

This release includes a range of new features and fixes known bugs and issues.
Expand Down
49 changes: 49 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,53 @@

## NetCoMi 1.0.3 <img src="man/figures/NetCoMi_logo_800x400_300dpi.png" align="right" width="200" />

This is a minor release with some bug fixes and changes in the
documentation.

### Bug fixes

- `netConstruct()` threw an error if the data had no row and/or column
names, which is fixed.

- An edge list is added to the output of `netConstruct()` (issue
[\#41](https://github.com/stefpeschel/NetCoMi/issues/41)). See the
help page for details.

- `SPRING`’s fast version of latent correlation computation
(implemented in [mixedCCA](https://github.com/irinagain/mixedCCA))
is currently not available due to deprecation of the R package
`chebpol`. The issue is fixed by setting the `netConstruct()`
parameter `measurePar$Rmethod` internally to “original” if SPRING is
used for association estimation.

- In `plot.microNetProps()`: The `xpd` parameter is changed to `NA` so
that plotting outside the plot region is possible (useful for
legends or additional text).

- Labels in the network plot can now be suppressed by setting
`labels = FALSE` (issue
[\#43](https://github.com/stefpeschel/NetCoMi/issues/43))

- The `netCompare()` function threw an error if one of the permutation
networks was empty, i.e. had no edges with weight different from
zero (issue
[\#38](https://github.com/stefpeschel/NetCoMi/issues/38)), which is
now fixed.

- Fix issues [\#29](https://github.com/stefpeschel/NetCoMi/issues/29)
and [\#40](https://github.com/stefpeschel/NetCoMi/issues/40), where
permutation tests did not terminate for small sample sizes. Now, if
the possible number of permutations (resulting from the sample size)
is smaller than that defined by the user, the function stops and
returns an error.

- Fix a bug in `diffnet()` (issue
[\#51](https://github.com/stefpeschel/NetCoMi/issues/51)), where
colors in differential networks could not be changed.

- `diffnet()` threw an error if the `netConstruct()` argument
`jointPrepro` was set to `TRUE`.

## NetCoMi 1.0.2

This release includes a range of new features and fixes known bugs and
Expand Down
Binary file modified man/figures/readme/netcomp_spring_4-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/readme/netcomp_spring_5-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/readme/netcomp_spring_6-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/readme/single_genus_2-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/readme/single_genus_3-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/readme/single_spring_3-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
56 changes: 47 additions & 9 deletions readme.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ Microbial associations are compared between the two experimantal settings
## Overview of methods included in NetCoMi

Here is an overview of methods available for network construction, together with
some information on the implementation in R:
some information on their implementation in R:

**Association measures:**

Expand Down Expand Up @@ -156,20 +156,33 @@ TSS, CSS, COM, VST, and the clr transformation are described in [Badri et al., 2
## Installation

```{r install, eval=FALSE}
#install.packages("devtools")
# Required packages
install.packages("devtools")
install.packages("BiocManager")
devtools::install_github("stefpeschel/NetCoMi", dependencies = TRUE,
# Install NetCoMi
devtools::install_github("stefpeschel/NetCoMi",
dependencies = c("Depends", "Imports", "LinkingTo"),
repos = c("https://cloud.r-project.org/",
BiocManager::repositories()))
```

If there are any errors during installation, please install the missing
dependencies manually.

Packages that are optionally required in certain settings are not installed
together with NetCoMi. These can be automatically installed using:
In particular the automatic installation of
[`SPRING`](https://github.com/GraceYoon/SPRING) and [`SpiecEasi`](https://github.com/zdk123/SpiecEasi) (only available on
GitHub) does sometimes not work. These packages can be installed as follows:

```{r install2, eval=FALSE}
devtools::install_github("GraceYoon/SPRING")
devtools::install_github("zdk123/SpiecEasi")
```

Packages that are optionally required in certain settings are not installed
together with NetCoMi. These can be installed automatically using:

```{r install3, eval=FALSE}
installNetCoMiPacks()
# Please check:
Expand Down Expand Up @@ -211,7 +224,7 @@ The data are filtered within `netConstruct()` as follows:

- Only samples with a total number of reads of at least 1000 are included
(argument `filtSamp`).
- Only the 100 taxa with highest frequency are included (argument `filtTax`).
- Only the 50 taxa with highest frequency are included (argument `filtTax`).

`measure` defines the association or dissimilarity measure, which is `"spring"`
in our case. Additional arguments are passed to `SPRING()` via `measurePar`.
Expand All @@ -232,10 +245,10 @@ weights in the network plot.
The `verbose` argument is set to 3 so that all messages generated by
`netConstruct()` as well as messages of external functions are printed.

```{r single_spring}
```{r single_spring, eval=FALSE}
net_single <- netConstruct(amgut1.filt,
filtTax = "highestFreq",
filtTaxPar = list(highestFreq = 100),
filtTaxPar = list(highestFreq = 50),
filtSamp = "totalReads",
filtSampPar = list(totalReads = 1000),
measure = "spring",
Expand All @@ -249,6 +262,21 @@ net_single <- netConstruct(amgut1.filt,
seed = 123456)
```

```{r single_spring2, eval=FALSE, echo=FALSE}
saveRDS(net_single, file = "./data/net_single_spring.rds")
```

```{r single_spring3, eval=TRUE, echo=FALSE}
net_single <- readRDS("./data/net_single_spring.rds")
```


**Note:** Since the fast version of latent correlation computation (for which
the [mixedCCA](https://github.com/irinagain/mixedCCA) package is used in `SPRING`)
is currently unavailable, the `SPRING` parameter `Rmethod` is internally set to
"original". Accordingly, execution time is currently considerably increased for
the SPRING approach.

**Analyzing the constructed network**

NetCoMi's `netAnalyze()` function is used for analyzing the constructed
Expand Down Expand Up @@ -587,13 +615,15 @@ The two resulting phyloseq objects (we ignore the group

We select the 50 nodes with highest variance to get smaller networks.

```{r netcomp_spring_1}
```{r netcomp_spring_0}
# devtools::install_github("vmikk/metagMisc")
# Split the phyloseq object into two groups
amgut_split <- metagMisc::phyloseq_sep_variable(amgut2.filt.phy,
"SEASONAL_ALLERGIES")
```

```{r netcomp_spring_1, eval = FALSE}
# Network construction
net_season <- netConstruct(data = amgut_split$no,
data2 = amgut_split$yes,
Expand All @@ -610,6 +640,14 @@ net_season <- netConstruct(data = amgut_split$no,
seed = 123456)
```

```{r netcomp_spring_1a, eval=FALSE, echo=FALSE}
saveRDS(net_season, file = "./data/net_season.rds")
```

```{r netcomp_spring_1s, eval=TRUE, echo=FALSE}
net_season <- readRDS("./data/net_season.rds")
```

Alternatively, a group vector could be passed to `group`, according to which
the data set is split into two groups:

Expand Down
Loading

0 comments on commit 65a4790

Please sign in to comment.