Skip to content

Commit 19af3da

Browse files
committed
reestructure pkg files, add citation and correct few links in doc
1 parent 34211cd commit 19af3da

File tree

12 files changed

+254
-63
lines changed

12 files changed

+254
-63
lines changed

.github/workflows/CI.yaml

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
name: CI
22
on:
3-
pull_request:
4-
branches:
5-
- main
63
push:
74
branches:
85
- main
96
tags: '*'
7+
pull_request:
108
jobs:
119
test:
1210
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
@@ -15,8 +13,7 @@ jobs:
1513
fail-fast: false
1614
matrix:
1715
version:
18-
- '1.6' # Replace this with the minimum Julia version that your package supports. E.g. if your package requires Julia 1.5 or higher, change this to '1.5'.
19-
- '1' # Leave this line unchanged. '1' will automatically expand to the latest stable 1.x release of Julia.
16+
- '1.6'
2017
- 'nightly'
2118
os:
2219
- ubuntu-latest
@@ -49,12 +46,18 @@ jobs:
4946
runs-on: ubuntu-latest
5047
steps:
5148
- uses: actions/checkout@v2
52-
- uses: julia-actions/setup-julia@latest
49+
- uses: julia-actions/setup-julia@v1
5350
with:
54-
version: '1.6'
55-
- name: Install dependencies
56-
run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
57-
- name: Build and deploy
51+
version: '1'
52+
- uses: julia-actions/julia-buildpkg@v1
53+
- uses: julia-actions/julia-docdeploy@v1
5854
env:
59-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # For authentication with GitHub Actions token
60-
run: julia --project=docs/ docs/make.jl
55+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
56+
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
57+
- run: |
58+
julia --project=docs -e '
59+
using Documenter: DocMeta, doctest
60+
using ClusterAnalysis
61+
DocMeta.setdocmeta!(ClusterAnalysis, :DocTestSetup, :(using ClusterAnalysis); recursive=true)
62+
doctest(ClusterAnalysis)'
63+

.github/workflows/CompatHelper.yml

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -7,26 +7,10 @@ jobs:
77
CompatHelper:
88
runs-on: ubuntu-latest
99
steps:
10-
- name: "Add the General registry via Git"
11-
run: |
12-
import Pkg
13-
ENV["JULIA_PKG_SERVER"] = ""
14-
Pkg.Registry.add("General")
15-
shell: julia --color=yes {0}
16-
- name: "Install CompatHelper"
17-
run: |
18-
import Pkg
19-
name = "CompatHelper"
20-
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
21-
version = "3"
22-
Pkg.add(; name, uuid, version)
23-
shell: julia --color=yes {0}
24-
- name: "Run CompatHelper"
25-
run: |
26-
import CompatHelper
27-
CompatHelper.main()
28-
shell: julia --color=yes {0}
10+
- name: Pkg.add("CompatHelper")
11+
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
12+
- name: CompatHelper.main()
2913
env:
3014
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3115
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
32-
# COMPATHELPER_PRIV: ${{ secrets.COMPATHELPER_PRIV }}
16+
run: julia -e 'using CompatHelper; CompatHelper.main()'

.github/workflows/TagBot.yaml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
name: TagBot
2-
32
on:
43
issue_comment:
54
types:
65
- created
76
workflow_dispatch:
8-
97
jobs:
108
TagBot:
119
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
@@ -14,4 +12,4 @@ jobs:
1412
- uses: JuliaRegistries/TagBot@v1
1513
with:
1614
token: ${{ secrets.GITHUB_TOKEN }}
17-
ssh: ${{ secrets.DOCUMENTER_KEY }}
15+
ssh: ${{ secrets.DOCUMENTER_KEY }}

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
11
.vscode
2-
Manifest.toml
2+
*.jl.*.cov
3+
*.jl.cov
4+
*.jl.mem
5+
/Manifest.toml
6+
/docs/build/

CITATION.cff

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
authors:
2+
-
3+
family-names: Leal
4+
given-names: "Augusto Cesar"
5+
-
6+
family-names: Carvalho
7+
given-names: Elias
8+
cff-version: "1.1.0"
9+
date-released: 2021-10-19
10+
keywords:
11+
- kmeans
12+
- dbscan
13+
- cluster
14+
- julia
15+
license: MIT
16+
message: "Use the following metadata to cite our fine selection of goods"
17+
repository-code: "https://github.com/AugustoCL/ClusterAnalysis.jl"
18+
title: "ClusterAnalysis.jl"
19+
version: "0.1.0"
20+
type: software

Project.toml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,14 @@ Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
1010
Tables = "bd369af6-aec1-5ad0-b16a-f7cc5008161c"
1111

1212
[compat]
13-
julia = "1"
13+
julia = "1.6"
1414
LinearAlgebra = "1.6"
1515
NearestNeighbors = "0.4.9"
1616
Statistics = "1.4.0"
1717
Tables = "1.6.0"
18+
19+
[extras]
20+
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
21+
22+
[targets]
23+
test = ["Test"]

README.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
# ClusterAnalysis.jl
22

3-
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://augustocl.github.io/ClusterAnalysis.jl/)
3+
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://AugustoCL.github.io/ClusterAnalysis.jl/stable)
4+
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://AugustoCL.github.io/ClusterAnalysis.jl/dev)
5+
[![Build Status](https://github.com/AugustoCL/ClusterAnalysis.jl/workflows/CI/badge.svg)](https://github.com/AugustoCL/ClusterAnalysis.jl/actions)
6+
[![Coverage](https://codecov.io/gh/AugustoCL/ClusterAnalysis.jl/branch/main/graph/badge.svg)](https://codecov.io/gh/AugustoCL/ClusterAnalysis.jl)
7+
48

59
<img src="docs/src/plot_dbscan.png" width="70%">
610

7-
This package was <ins>**built from scratch**</ins>, entirely in [Julia Lang](julialang.org/), and implements a few popular clustering algorithms like K-Means and DBSCAN.
11+
This package was <ins>**built from scratch**</ins>, entirely in [Julia Lang](https://julialang.org/), and implements a few popular clustering algorithms like K-Means and DBSCAN.
812

913
This is mostly a learning experiment, but the package were also built and documented to be used by anyone, Plug-and-Play. Just input your data as an Array or a [Tables.jl](https://discourse.julialang.org/t/tables-jl-a-table-interface-for-everyone/14071) type (like [DataFrames.jl](https://dataframes.juliadata.org/stable/)), then start training your clusters algorithms and analyze your results.
1014

@@ -17,8 +21,8 @@ Currently we implemented two types of algorithms, a partitioned based ([K-Means]
1721
1822
>It's a great introduction to the algorithm and a good resource to read along with the source code.
1923
20-
- [DBSCAN](https://augustocl.github.io/ClusterAnalysis.jl/algorithms/dbscan.html)
21-
- [K-Means](https://augustocl.github.io/ClusterAnalysis.jl/algorithms/kmeans.html)
24+
- [DBSCAN](https://augustocl.github.io/ClusterAnalysis.jl/dev/algorithms/dbscan.html)
25+
- [K-Means](https://augustocl.github.io/ClusterAnalysis.jl/dev/algorithms/kmeans.html)
2226

2327
## How to install ClusterAnalysis.jl
2428

docs/Manifest.toml

Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
# This file is machine-generated - editing it directly is not advised
2+
3+
[[ANSIColoredPrinters]]
4+
git-tree-sha1 = "574baf8110975760d391c710b6341da1afa48d8c"
5+
uuid = "a4c015fc-c6ff-483c-b24f-f7ea428134e9"
6+
version = "0.0.1"
7+
8+
[[Base64]]
9+
uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
10+
11+
[[ClusterAnalysis]]
12+
deps = ["LinearAlgebra", "NearestNeighbors", "Statistics", "Tables"]
13+
git-tree-sha1 = "383f6b3c54491f62321e17005a5e0cc50acb73f9"
14+
uuid = "10587292-549a-4141-aed9-b9dca56acf27"
15+
version = "0.1.0"
16+
17+
[[DataAPI]]
18+
git-tree-sha1 = "cc70b17275652eb47bc9e5f81635981f13cea5c8"
19+
uuid = "9a962f9c-6df0-11e9-0e5d-c546b8b5ee8a"
20+
version = "1.9.0"
21+
22+
[[DataValueInterfaces]]
23+
git-tree-sha1 = "bfc1187b79289637fa0ef6d4436ebdfe6905cbd6"
24+
uuid = "e2d170a0-9d28-54be-80f0-106bbe20a464"
25+
version = "1.0.0"
26+
27+
[[Dates]]
28+
deps = ["Printf"]
29+
uuid = "ade2ca70-3891-5945-98fb-dc099432e06a"
30+
31+
[[Distances]]
32+
deps = ["LinearAlgebra", "Statistics", "StatsAPI"]
33+
git-tree-sha1 = "09d9eaef9ef719d2cd5d928a191dc95be2ec8059"
34+
uuid = "b4f34e82-e78d-54a5-968a-f98e89d6e8f7"
35+
version = "0.10.5"
36+
37+
[[DocStringExtensions]]
38+
deps = ["LibGit2"]
39+
git-tree-sha1 = "b19534d1895d702889b219c382a6e18010797f0b"
40+
uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
41+
version = "0.8.6"
42+
43+
[[Documenter]]
44+
deps = ["ANSIColoredPrinters", "Base64", "Dates", "DocStringExtensions", "IOCapture", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
45+
git-tree-sha1 = "f425293f7e0acaf9144de6d731772de156676233"
46+
uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
47+
version = "0.27.10"
48+
49+
[[IOCapture]]
50+
deps = ["Logging", "Random"]
51+
git-tree-sha1 = "f7be53659ab06ddc986428d3a9dcc95f6fa6705a"
52+
uuid = "b5f81e59-6552-4d32-b1f0-c071b021bf89"
53+
version = "0.2.2"
54+
55+
[[InteractiveUtils]]
56+
deps = ["Markdown"]
57+
uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240"
58+
59+
[[IteratorInterfaceExtensions]]
60+
git-tree-sha1 = "a3f24677c21f5bbe9d2a714f95dcd58337fb2856"
61+
uuid = "82899510-4779-5014-852e-03e436cf321d"
62+
version = "1.0.0"
63+
64+
[[JSON]]
65+
deps = ["Dates", "Mmap", "Parsers", "Unicode"]
66+
git-tree-sha1 = "8076680b162ada2a031f707ac7b4953e30667a37"
67+
uuid = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
68+
version = "0.21.2"
69+
70+
[[LibGit2]]
71+
deps = ["Base64", "NetworkOptions", "Printf", "SHA"]
72+
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433"
73+
74+
[[Libdl]]
75+
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
76+
77+
[[LinearAlgebra]]
78+
deps = ["Libdl"]
79+
uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
80+
81+
[[Logging]]
82+
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"
83+
84+
[[Markdown]]
85+
deps = ["Base64"]
86+
uuid = "d6f4376e-aef5-505a-96c1-9c027394607a"
87+
88+
[[Mmap]]
89+
uuid = "a63ad114-7e13-5084-954f-fe012c677804"
90+
91+
[[NearestNeighbors]]
92+
deps = ["Distances", "StaticArrays"]
93+
git-tree-sha1 = "16baacfdc8758bc374882566c9187e785e85c2f0"
94+
uuid = "b8a86587-4115-5ab1-83bc-aa920d37bbce"
95+
version = "0.4.9"
96+
97+
[[NetworkOptions]]
98+
uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908"
99+
100+
[[Parsers]]
101+
deps = ["Dates"]
102+
git-tree-sha1 = "f19e978f81eca5fd7620650d7dbea58f825802ee"
103+
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0"
104+
version = "2.1.0"
105+
106+
[[Printf]]
107+
deps = ["Unicode"]
108+
uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7"
109+
110+
[[REPL]]
111+
deps = ["InteractiveUtils", "Markdown", "Sockets", "Unicode"]
112+
uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb"
113+
114+
[[Random]]
115+
deps = ["Serialization"]
116+
uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
117+
118+
[[SHA]]
119+
uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce"
120+
121+
[[Serialization]]
122+
uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b"
123+
124+
[[Sockets]]
125+
uuid = "6462fe0b-24de-5631-8697-dd941f90decc"
126+
127+
[[SparseArrays]]
128+
deps = ["LinearAlgebra", "Random"]
129+
uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
130+
131+
[[StaticArrays]]
132+
deps = ["LinearAlgebra", "Random", "Statistics"]
133+
git-tree-sha1 = "3c76dde64d03699e074ac02eb2e8ba8254d428da"
134+
uuid = "90137ffa-7385-5640-81b9-e52037218182"
135+
version = "1.2.13"
136+
137+
[[Statistics]]
138+
deps = ["LinearAlgebra", "SparseArrays"]
139+
uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
140+
141+
[[StatsAPI]]
142+
git-tree-sha1 = "1958272568dc176a1d881acb797beb909c785510"
143+
uuid = "82ae8749-77ed-4fe6-ae5f-f523153014b0"
144+
version = "1.0.0"
145+
146+
[[TableTraits]]
147+
deps = ["IteratorInterfaceExtensions"]
148+
git-tree-sha1 = "c06b2f539df1c6efa794486abfb6ed2022561a39"
149+
uuid = "3783bdb8-4a98-5b6b-af9a-565f29a5fe9c"
150+
version = "1.0.1"
151+
152+
[[Tables]]
153+
deps = ["DataAPI", "DataValueInterfaces", "IteratorInterfaceExtensions", "LinearAlgebra", "TableTraits", "Test"]
154+
git-tree-sha1 = "fed34d0e71b91734bf0a7e10eb1bb05296ddbcd0"
155+
uuid = "bd369af6-aec1-5ad0-b16a-f7cc5008161c"
156+
version = "1.6.0"
157+
158+
[[Test]]
159+
deps = ["InteractiveUtils", "Logging", "Random", "Serialization"]
160+
uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
161+
162+
[[Unicode]]
163+
uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"

docs/Project.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
[deps]
2+
ClusterAnalysis = "10587292-549a-4141-aed9-b9dca56acf27"
23
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"

docs/make.jl

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
11
# push!(LOAD_PATH,"../src/")
22
using Documenter, ClusterAnalysis
33

4+
DocMeta.setdocmeta!(ClusterAnalysis, :DocTestSetup, :(using ClusterAnalysis); recursive=true)
5+
46
makedocs(
57
modules=[ClusterAnalysis],
6-
format=Documenter.HTML(prettyurls=false),
8+
authors="AugustoCL <[email protected]>, Elias Carvalho <[email protected]>",
9+
repo="https://github.com/AugustoCL/ClusterAnalysis.jl",
10+
sitename="ClusterAnalysis.jl",
11+
format=Documenter.HTML(;
12+
prettyurls=get(ENV, "CI", "false") == "true",
13+
canonical="https://AugustoCL.github.io/ClusterAnalysis.jl",
14+
assets=String[],
15+
),
716
pages=[
817
"Home" => "index.md",
918
"Algorithms" => [
@@ -14,10 +23,7 @@ makedocs(
1423
"Functions" => "API/functions.md",
1524
"Types" => "API/types.md"
1625
]
17-
],
18-
repo="https://github.com/AugustoCL/ClusterAnalysis.jl",
19-
sitename="ClusterAnalysis.jl",
20-
authors="AugustoCL <[email protected]>, Elias Carvalho <[email protected]>"
26+
]
2127
)
2228

2329
deploydocs(

0 commit comments

Comments
 (0)