Skip to content

Commit a1bac49

Browse files
committed
Merge branch 'release/v0.13.0'
2 parents ab62841 + 02cf9d8 commit a1bac49

File tree

104 files changed

+4431
-13066
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

104 files changed

+4431
-13066
lines changed

.gitignore

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,23 @@
1+
# Directories to ignore:
2+
3+
*.ipynb_checkpoints/
4+
data/
5+
docs/build/
6+
docs/site/
7+
docs/src/examples/
8+
input/
9+
output/
10+
11+
# Files to ignore:
12+
113
.DS_Store
214
*.aux
3-
*.ipynb_checkpoints/
4-
*.jl.*.cov
515
*.jl.cov
16+
*.jl.*.cov
617
*.jl.mem
718
*.log
8-
data/
919
deps/custom_preamble.tex
1020
deps/deps.jl
1121
deps/pdf2svg.svg
1222
deps/showed_warning
13-
docs/build
14-
input/
15-
output/
1623
scratch.jl

.travis.yml

Lines changed: 38 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,49 @@
1-
## Documentation: http://docs.travis-ci.com/user/languages/julia/
21
language: julia
2+
33
os:
4-
- linux
5-
- osx
4+
- linux
5+
- osx
6+
67
julia:
7-
- 0.6
8-
# - nightly
8+
- 0.6
9+
- nightly
10+
911
notifications:
10-
email: false
12+
email: false
13+
1114
git:
12-
depth: 99999999
15+
depth: 99999999
1316

14-
## Allow failures on nightly julia:
1517
matrix:
16-
allow_failures:
17-
- julia: nightly
18+
allow_failures:
19+
- julia: nightly
1820

1921
addons:
20-
apt:
21-
packages:
22-
- gfortran
23-
- pdf2svg
24-
- pgf
25-
- poppler-utils # provides /usr/bin/pdftoppm
26-
- texlive-binaries
27-
- texlive-latex-base
28-
- texlive-latex-extra
29-
- texlive-pictures
22+
apt:
23+
packages:
24+
- gfortran
25+
- pdf2svg
26+
- pgf
27+
- poppler-utils
28+
- texlive-binaries
29+
- texlive-latex-base
30+
- texlive-latex-extra
31+
- texlive-pictures
3032

3133
before_install:
32-
# update homebrew
33-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi
34-
# install mactex
35-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew cask install basictex; fi
36-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export PATH=/Library/TeX/texbin:"$PATH"; fi
37-
# update tlmgr
38-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr update --self; fi
39-
# install tex packages
40-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install luatex85; fi
41-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install pgfplots; fi
42-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install standalone; fi
43-
# install pdf2svg
44-
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install pdf2svg; fi
34+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi
35+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew cask install basictex; fi
36+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export PATH=/Library/TeX/texbin:"$PATH"; fi
37+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr update --self; fi
38+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install luatex85; fi
39+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install pgfplots; fi
40+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo tlmgr install standalone; fi
41+
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install pdf2svg; fi
42+
43+
script:
44+
- julia --color=yes -e 'Pkg.clone(pwd())'
45+
- julia --color=yes -e 'Pkg.build("PredictMD")'
46+
- julia --check-bounds=yes --color=yes -e 'Pkg.test("PredictMD", coverage=true)'
47+
48+
after_success:
49+
- julia -e 'cd(Pkg.dir("PredictMD")); include(joinpath("docs", "deploy_docs.jl"))'

CONTRIBUTING.md

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,6 @@ This document provides information on contributing to the PredictMD source code.
1414
</tr>
1515
<tr>
1616
<td align="left"><a href="#2-setting-up-the-predictmd-repo">2. Setting up the PredictMD repo</a></td>
17-
</tr>
18-
<tr>
19-
<td align="left"><a href="#3-working-with-examples">3. Working with examples</a></td>
2017
</tr>
2118
</tbody>
2219
</table>
@@ -156,41 +153,3 @@ cd ~/.julia/v0.6/PredictMD
156153
```bash
157154
git config commit.gpgsign true && git remote set-url origin https://github.com/bcbi/PredictMD.jl.git && git remote set-url --push origin git@github.com:bcbi/PredictMD.jl.git && git checkout master && git checkout develop && git flow init -fd && git checkout develop && git fetch --all --prune
158155
```
159-
160-
## 3. Working with examples
161-
162-
Some of the examples are provided as Jupyter notebooks as a convinient way to visualize and interact with the code. However, we also like to mantain corresponding plain Julia scripts that are in-sync with the notebooks. A convinient way to do so, is to add a post-save hook to your Jupyter configuration file.
163-
164-
1. Open you jupyter configuration file ~/.jupyter/jupyter_notebook_config.py. If the file does not exist you can generate it by running `jupyter notebook --generate-config`
165-
166-
2. Add the following code to the top of the file
167-
168-
```python
169-
#-----------------------------------------------------------------------------
170-
# Auto save script version of notebook
171-
# Reference: https://svds.com/jupyter-notebook-best-practices-for-data-science/
172-
#-----------------------------------------------------------------------------
173-
174-
import os
175-
from subprocess import check_call
176-
177-
def post_save(model, os_path, contents_manager):
178-
"""post-save hook for converting notebooks to .py scripts"""
179-
if model['type'] != 'notebook':
180-
return # only do this for notebooks
181-
d, fname = os.path.split(os_path)
182-
check_call(['jupyter', 'nbconvert', '--to', 'script', fname], cwd=d)
183-
184-
c.FileContentsManager.post_save_hook = post_save
185-
```
186-
187-
**Note:** This behavior is global. If you want to have this saving only when in a particular folder, you can create multiple configuration files as a work-around. First create a new profile name via a bash command line:
188-
```bash
189-
export JUPYTER_CONFIG_DIR=~/.jupyter_profile2
190-
jupyter notebook --generate-config
191-
```
192-
This will create a new directory and file at `~/.jupyter_profile2/jupyter_notebook_config.py` Then run jupyter notebook and work as usual. To switch back to your default profile you will have to set (either by hand, shell function, or your .bashrc) back to:
193-
194-
```bash
195-
export JUPYTER_CONFIG_DIR=~/.jupyter
196-
```

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,22 @@
33
<table>
44
<thead>
55
<tr>
6+
<th>branch</th>
67
<th>master</th>
78
<th>develop</th>
89
</tr>
910
</thead>
1011
<tbody>
1112
<tr>
13+
<td>travis</td>
1214
<td><a href="https://travis-ci.org/bcbi/PredictMD.jl/branches"><img alt="Build Status (master)" title="Build Status (master)" src="https://travis-ci.org/bcbi/PredictMD.jl.svg?branch=master"></a></td>
1315
<td><a href="https://travis-ci.org/bcbi/PredictMD.jl/branches"><img alt="Build Status (develop)" title="Build Status (develop)" src="https://travis-ci.org/bcbi/PredictMD.jl.svg?branch=develop"></a></td>
1416
</tr>
17+
<tr>
18+
<td>docs</td>
19+
<td><a href="https://bcbi.github.io/PredictMD.jl/stable"><img alt="Documentation (stable)" title="Documentation (stable)" src="https://img.shields.io/badge/docs-stable-blue.svg"></a></td>
20+
<td><a href="https://bcbi.github.io/PredictMD.jl/latest"><img alt="Documentation (latest)" title="Documentation (latest)" src="https://img.shields.io/badge/docs-latest-blue.svg"></a></td>
21+
</tr>
1522
</tbody>
1623
</table>
1724

@@ -28,16 +35,13 @@ PredictMD is a [Julia](https://julialang.org/) package that provides a uniform i
2835
<td align="left"><a href="#1-prerequisites">1. Prerequisites</a></td>
2936
</tr>
3037
<tr>
31-
<td align="left"><a href="#2-installation-recommended-method">2. Installation (recommended method)</a></td>
32-
</tr>
33-
<tr>
34-
<td align="left"><a href="#3-installation-alternate-method-with-conda">3. Installation (alternate method with Conda)</a></td>
38+
<td align="left"><a href="#2-installation">2. Installation</a></td>
3539
</tr>
3640
<tr>
37-
<td align="left"><a href="#4-examples">4. Examples</a></td>
41+
<td align="left"><a href="#3-examples">3. Examples</a></td>
3842
</tr>
3943
<tr>
40-
<td align="left"><a href="#5-contributing">5. Contributing</a></td>
44+
<td align="left"><a href="#4-contributing">4. Contributing</a></td>
4145
</tr>
4246
</tbody>
4347
</table>
@@ -107,7 +111,7 @@ If you receive an error (e.g. "command not found"), download and install pdf2svg
107111
* macOS: [http://brewinstall.org/Install-pdf2svg-on-Mac-with-Brew/](http://brewinstall.org/Install-pdf2svg-on-Mac-with-Brew/)
108112
* GNU/Linux: [https://github.com/dawbarton/pdf2svg](https://github.com/dawbarton/pdf2svg)
109113

110-
## 2. Installation (recommended method)
114+
## 2. Installation
111115

112116
**Step 1:** Make sure that you have followed all of the instructions in [Section 1 (Prerequisites)](#1-prerequisites).
113117

@@ -126,11 +130,7 @@ If you receive the message "INFO: PredictMD tests passed", then you have success
126130

127131
If the tests still do not pass or if you still receive an error message, go to [https://github.com/bcbi/PredictMD.jl/issues/new](https://github.com/bcbi/PredictMD.jl/issues/new) and submit a new issue. Please include a screenshot of the error.
128132

129-
## 3. Installation (alternate method with Conda)
130-
131-
Alternatively, you can install PredictMD using the Conda package manager. Just follow the instructions here: [https://github.com/dilumaluthge/conda-predictmd-cpu](https://github.com/dilumaluthge/conda-predictmd-cpu)
132-
133-
## 4. Examples
133+
## 3. Examples
134134
The `examples/` folder contains several files that illustrate the usage of PredictMD:
135135

136136
<table>
@@ -158,6 +158,6 @@ The `examples/` folder contains several files that illustrate the usage of Predi
158158
<tbody>
159159
</table>
160160

161-
## 5. Contributing
161+
## 4. Contributing
162162

163163
If you would like to contribute to the PredictMD source code, please see [CONTRIBUTING.md](CONTRIBUTING.md).

REQUIRE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ BSON 0.1
66
CSV 0.2
77
ClassImbalance 0.2
88
Combinatorics 0.6
9+
Compat
910
Crayons 0.4
1011
DataFrames 0.11
1112
DecisionTree 0.6
@@ -27,7 +28,6 @@ NNlib 0.2
2728
NumericalIntegration 0.0.3
2829
PGFPlots 2.2
2930
PGFPlotsX 0.2
30-
PackageCompiler 0.3
3131
ProgressMeter 0.5
3232
RDatasets 0.3
3333
ROCAnalysis 0.2

docs/deploy_docs.jl

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
import Documenter
2+
import PredictMD
3+
4+
ENV["PREDICTMD_IS_DEPLOY_DOCS"] = "true"
5+
6+
Documenter.deploydocs(
7+
branch = "gh-pages",
8+
deps = Documenter.Deps.pip(
9+
"mkdocs",
10+
"pygments",
11+
"python-markdown-math",
12+
),
13+
julia = "0.6",
14+
latest = "develop",
15+
osname = "linux",
16+
repo = "github.com/bcbi/PredictMD.jl.git",
17+
target = "site",
18+
)
19+
20+
ENV["PREDICTMD_IS_DEPLOY_DOCS"] = "false"

0 commit comments

Comments
 (0)