Skip to content

Commit

Permalink
rename project and add license
Browse files Browse the repository at this point in the history
  • Loading branch information
yuehhua committed Jun 20, 2022
1 parent 6c45ecc commit 0302b92
Show file tree
Hide file tree
Showing 12 changed files with 47 additions and 26 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,6 @@ jobs:
- run: |
julia --project=docs -e '
using Documenter: DocMeta, doctest
using CDGRN
DocMeta.setdocmeta!(CDGRN, :DocTestSetup, :(using CDGRN); recursive=true)
doctest(CDGRN)'
using CDGRNs
DocMeta.setdocmeta!(CDGRNs, :DocTestSetup, :(using CDGRNs); recursive=true)
doctest(CDGRNs)'
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2022 Yueh-Hua Tu

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name = "CDGRN"
name = "CDGRNs"
uuid = "b97acbd9-7fbb-4cbc-bc29-58677f11bc5c"
authors = ["Yueh-Hua Tu <a504082002@gmail.com>"]
version = "0.0.1"
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# CDGRN.jl
# CDGRNs.jl

[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://yuehhua.github.io/CDGRN.jl/stable/)
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://yuehhua.github.io/CDGRN.jl/dev/)
[![Build Status](https://github.com/yuehhua/CDGRN.jl/actions/workflows/CI.yml/badge.svg?branch=main)](https://github.com/yuehhua/CDGRN.jl/actions/workflows/CI.yml?query=branch%3Amain)
[![Coverage](https://codecov.io/gh/yuehhua/CDGRN.jl/branch/main/graph/badge.svg)](https://codecov.io/gh/yuehhua/CDGRN.jl)
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://yuehhua.github.io/CDGRNs.jl/stable/)
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://yuehhua.github.io/CDGRNs.jl/dev/)
[![Build Status](https://github.com/yuehhua/CDGRNs.jl/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/yuehhua/CDGRNs.jl/actions/workflows/test.yml?query=branch%3Amain)
[![Coverage](https://codecov.io/gh/yuehhua/CDGRNs.jl/branch/main/graph/badge.svg)](https://codecov.io/gh/yuehhua/CDGRNs.jl)
2 changes: 1 addition & 1 deletion docs/Project.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[deps]
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
CDGRN = "b97acbd9-7fbb-4cbc-bc29-58677f11bc5c"
CDGRNs = "b97acbd9-7fbb-4cbc-bc29-58677f11bc5c"
14 changes: 7 additions & 7 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
using CDGRN
using CDGRNs
using Documenter

DocMeta.setdocmeta!(CDGRN, :DocTestSetup, :(using CDGRN); recursive=true)
DocMeta.setdocmeta!(CDGRNs, :DocTestSetup, :(using CDGRNs); recursive=true)

makedocs(;
modules=[CDGRN],
modules=[CDGRNs],
authors="Yueh-Hua Tu",
repo="https://github.com/yuehhua/CDGRN.jl/blob/{commit}{path}#{line}",
sitename="CDGRN.jl",
repo="https://github.com/yuehhua/CDGRNs.jl/blob/{commit}{path}#{line}",
sitename="CDGRNs.jl",
format=Documenter.HTML(;
prettyurls=get(ENV, "CI", "false") == "true",
canonical="https://yuehhua.github.io/CDGRN.jl",
canonical="https://yuehhua.github.io/CDGRNs.jl",
edit_link="main",
assets=String[],
),
Expand All @@ -20,6 +20,6 @@ makedocs(;
)

deploydocs(;
repo="github.com/yuehhua/CDGRN.jl",
repo="github.com/yuehhua/CDGRNs.jl",
devbranch="main",
)
8 changes: 4 additions & 4 deletions docs/src/index.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
```@meta
CurrentModule = CDGRN
CurrentModule = CDGRNs
```

# CDGRN
# CDGRNs

Documentation for [CDGRN](https://github.com/yuehhua/CDGRN.jl).
Documentation for [CDGRNs](https://github.com/yuehhua/CDGRNs.jl).

```@index
```

```@autodocs
Modules = [CDGRN]
Modules = [CDGRNs]
```
2 changes: 1 addition & 1 deletion src/CDGRN.jl → src/CDGRNs.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module CDGRN
module CDGRNs

using GaussianMixtures: GaussianMixture, size
using LinearAlgebra
Expand Down
2 changes: 1 addition & 1 deletion src/cdgrn.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ function corr_table(pairs)
# unit: component
cor_pairs = map(x -> (tf=x[:tf_name], target=x[:gene_name], best_k=x[:best_k], corr=correlation(x[:model])), pairs)
df = DataFrames.flatten(DataFrame(cor_pairs), :corr)
df.adjusted_corr = CDGRN.fisher_transform(df.corr)
df.adjusted_corr = CDGRNs.fisher_transform(df.corr)
return df
end

Expand Down
2 changes: 1 addition & 1 deletion src/interface.jl
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ function test_cdf(ρ1, ρ2, condition1, condition2; step=0.1, plot_dir=nothing,
end

function save_cdgrn(filename, cdgrn, tfs, prof, cntx)
context_cor = CDGRN.cor(cdgrn, tfs, prof, cntx)
context_cor = CDGRNs.cor(cdgrn, tfs, prof, cntx)
context_cor = context_cor[.!isnan.(context_cor.ρ), :]
context_cor.reg_type = context_cor.ρ .> 0
context_cor.reg_stng = abs.(context_cor.ρ)
Expand Down
2 changes: 1 addition & 1 deletion test/mixture.jl
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ using GLM
@test check_confint(model.models[2].β, stderror(model.models[2]), GLM.coef(model1_true)) |
check_confint(model.models[2].β, stderror(model.models[2]), GLM.coef(model2_true))

model = fit(MixtureRegression{2}, data.X, data.Y; max_iter=iter, init=()->CDGRN.random_init(k, 2n))
model = fit(MixtureRegression{2}, data.X, data.Y; max_iter=iter, init=()->CDGRNs.random_init(k, 2n))
@test check_confint(model.models[1].β, stderror(model.models[1]), GLM.coef(model1_true)) |
check_confint(model.models[1].β, stderror(model.models[1]), GLM.coef(model2_true))
@test check_confint(model.models[2].β, stderror(model.models[2]), GLM.coef(model1_true)) |
Expand Down
2 changes: 1 addition & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using CDGRN
using CDGRNs
using DataFrames
using CSV
using SnowyOwl
Expand Down

2 comments on commit 0302b92

@yuehhua
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/62693

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.0.1 -m "<description of version>" 0302b9218999c9ff720e1abbf46e8c29fe82adff
git push origin v0.0.1

Please sign in to comment.