using TDAmapper;
import GeometricDatasets as gd;
Start here
Installation
In Julia, type
] add https://github.com/JuliaTDA/TDAmapper.jl https://github.com/JuliaTDA/GeometricDatasets.jl
The ]
character mark the command to be executed in Julia package mode.
First usage
Load the packages
create a torus
= gd.torus(2000) X
3×2000 Matrix{Float64}:
-2.17768 1.35623 -0.0562065 … 0.906515 -1.53537 -2.11367
3.34555 -2.3255 2.30534 2.2027 -1.38697 -1.66377
-0.127294 0.951413 -0.719997 -0.786131 -0.365191 0.950715
define the filter values
= X[1, :]; fv
and the covering
= uniform(fv, overlap = 150); C
Calculate the mapper
= mapper(X, fv, C; clustering = cluster_dbscan(;radius = 1)) mp
and plot the results
= node_colors(mp, fv)
node_values
mapper_plot(mp, node_values = node_values)
New to Julia?
That was too much Julia for you? No problem! You can learn more with some very nice books like these: