From 206c088f7f30bb4819e2cda44193b0a60e6d2637 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:16:27 +0100 Subject: [PATCH 01/17] bug --- .vscode/workflows/CI.yml | 64 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 .vscode/workflows/CI.yml diff --git a/.vscode/workflows/CI.yml b/.vscode/workflows/CI.yml new file mode 100644 index 0000000..ba0d3ee --- /dev/null +++ b/.vscode/workflows/CI.yml @@ -0,0 +1,64 @@ +name: CI +on: + push: + branches: + - main + pull_request: +jobs: + test: + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + version: + - '1' + os: + - ubuntu-latest + arch: + - x64 + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@v1 + with: + version: ${{ matrix.version }} + arch: ${{ matrix.arch }} + - uses: actions/cache@v1 + env: + cache-name: cache-artifacts + with: + path: ~/.julia/artifacts + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} + restore-keys: | + ${{ runner.os }}-test-${{ env.cache-name }}- + ${{ runner.os }}-test- + ${{ runner.os }}- + - uses: julia-actions/julia-buildpkg@v1 + - uses: julia-actions/julia-runtest@v1 + - uses: julia-actions/julia-processcoverage@v1 + - uses: codecov/codecov-action@v1 + with: + file: lcov.info + docs: + name: Documentation + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@v1 + with: + version: '1' + - run: | + julia --project=docs -e ' + using Pkg + Pkg.develop(PackageSpec(path=pwd())) + Pkg.instantiate()' + - run: | + julia --project=docs -e ' + using Documenter: DocMeta, doctest + using UnfoldMakie + DocMeta.setdocmeta!(UnfoldMakie, :DocTestSetup, :(using UnfoldMakie); recursive=true) + doctest(UnfoldMakie)' + - run: julia --project=docs docs/make.jl + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} From eeb3bd230aa2c10e8edcfee2a8800a8d0a1d1111 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:22:20 +0100 Subject: [PATCH 02/17] big move --- docs/Project.toml | 8 ++++++++ docs/make.jl | 48 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 docs/Project.toml create mode 100644 docs/make.jl diff --git a/docs/Project.toml b/docs/Project.toml new file mode 100644 index 0000000..27a5312 --- /dev/null +++ b/docs/Project.toml @@ -0,0 +1,8 @@ +[deps] +CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0" +DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" +DataFramesMeta = "1313f7d8-7da2-5740-9ea0-a2ca25f37964" +DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" +Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" +Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306" +Unfold = "181c99d8-e21b-4ff3-b70b-c233eddec679" diff --git a/docs/make.jl b/docs/make.jl new file mode 100644 index 0000000..0c07c91 --- /dev/null +++ b/docs/make.jl @@ -0,0 +1,48 @@ +using ERPExplorer +using Documenter +using DocStringExtensions + +# preload once + +using CairoMakie +const Makie = CairoMakie # - for references +using Unfold +using DataFrames +using DataFramesMeta +using Literate +using Glob + +GENERATED = joinpath(@__DIR__, "src", "generated") +SOURCE = joinpath(@__DIR__, "literate") +for subfolder ∈ ["intro"] #["how_to", "intro", "tutorials", "explanations"] + local SOURCE_FILES = Glob.glob(subfolder * "/*.jl", SOURCE) + foreach(fn -> Literate.markdown(fn, GENERATED * "/" * subfolder), SOURCE_FILES) +end + +DocMeta.setdocmeta!(ERPExplorer, :DocTestSetup, :(using ERPExplorer); recursive = true) + +makedocs(; + modules = [ERPExplorer], + authors = "Vladimir Mikheev, Simon Danisch, Benedikt Ehinger", + repo = Documenter.Remotes.GitHub("s-ccs", "ERPExplorer.jl"), + sitename = "ERPExplorer.jl", + warnonly = :cross_references, + format = Documenter.HTML(; + prettyurls = get(ENV, "CI", "false") == "true", + canonical = "https://s-css.github.io/ERPExplorer.jl", + assets = String[], + ), + pages = [ + "ERPExplorer highlights" => "index.md", + #"Plotting" => "generated/intro/toposeries.md", + #"Diagnostics" => "generated/intro/gnostics.md", + #"API / DocStrings" => "api.md", + ], +) + +deploydocs(; + repo = "github.com/s-ccs/ERPExplorer.jl", + devbranch = "main", + versions = "v#.#", + push_preview = true, +) From 6f29112bd41dbe4c217c3505da61051332f0e279 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:23:31 +0100 Subject: [PATCH 03/17] mistake --- .vscode/workflows/CI.yml | 64 ---------------------------------------- 1 file changed, 64 deletions(-) delete mode 100644 .vscode/workflows/CI.yml diff --git a/.vscode/workflows/CI.yml b/.vscode/workflows/CI.yml deleted file mode 100644 index ba0d3ee..0000000 --- a/.vscode/workflows/CI.yml +++ /dev/null @@ -1,64 +0,0 @@ -name: CI -on: - push: - branches: - - main - pull_request: -jobs: - test: - name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} - runs-on: ${{ matrix.os }} - strategy: - fail-fast: false - matrix: - version: - - '1' - os: - - ubuntu-latest - arch: - - x64 - steps: - - uses: actions/checkout@v2 - - uses: julia-actions/setup-julia@v1 - with: - version: ${{ matrix.version }} - arch: ${{ matrix.arch }} - - uses: actions/cache@v1 - env: - cache-name: cache-artifacts - with: - path: ~/.julia/artifacts - key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} - restore-keys: | - ${{ runner.os }}-test-${{ env.cache-name }}- - ${{ runner.os }}-test- - ${{ runner.os }}- - - uses: julia-actions/julia-buildpkg@v1 - - uses: julia-actions/julia-runtest@v1 - - uses: julia-actions/julia-processcoverage@v1 - - uses: codecov/codecov-action@v1 - with: - file: lcov.info - docs: - name: Documentation - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: julia-actions/setup-julia@v1 - with: - version: '1' - - run: | - julia --project=docs -e ' - using Pkg - Pkg.develop(PackageSpec(path=pwd())) - Pkg.instantiate()' - - run: | - julia --project=docs -e ' - using Documenter: DocMeta, doctest - using UnfoldMakie - DocMeta.setdocmeta!(UnfoldMakie, :DocTestSetup, :(using UnfoldMakie); recursive=true) - doctest(UnfoldMakie)' - - run: julia --project=docs docs/make.jl - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} From c4fa7064be9c7bce1da8e5bf1ef26ad100adada1 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:24:22 +0100 Subject: [PATCH 04/17] actions --- .github/workflows/CI.yml | 64 ++++++++++++++++++++++++++++++ .github/workflows/CompatHelper.yml | 16 ++++++++ .github/workflows/TagBot.yml | 15 +++++++ .github/workflows/format.yml | 8 ++++ 4 files changed, 103 insertions(+) create mode 100644 .github/workflows/CI.yml create mode 100644 .github/workflows/CompatHelper.yml create mode 100644 .github/workflows/TagBot.yml create mode 100644 .github/workflows/format.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 0000000..6dc10b8 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,64 @@ +name: CI +on: + push: + branches: + - main + pull_request: +jobs: + test: + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + version: + - '1' + os: + - ubuntu-latest + arch: + - x64 + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@v1 + with: + version: ${{ matrix.version }} + arch: ${{ matrix.arch }} + - uses: actions/cache@v1 + env: + cache-name: cache-artifacts + with: + path: ~/.julia/artifacts + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} + restore-keys: | + ${{ runner.os }}-test-${{ env.cache-name }}- + ${{ runner.os }}-test- + ${{ runner.os }}- + - uses: julia-actions/julia-buildpkg@v1 + - uses: julia-actions/julia-runtest@v1 + - uses: julia-actions/julia-processcoverage@v1 + - uses: codecov/codecov-action@v1 + with: + file: lcov.info + docs: + name: Documentation + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@v1 + with: + version: '1' + - run: | + julia --project=docs -e ' + using Pkg + Pkg.develop(PackageSpec(path=pwd())) + Pkg.instantiate()' + - run: | + julia --project=docs -e ' + using Documenter: DocMeta, doctest + using ERPExplorer + DocMeta.setdocmeta!(ERPExplorer, :DocTestSetup, :(using ERPExplorer); recursive=true) + doctest(ERPExplorer)' + - run: julia --project=docs docs/make.jl + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} diff --git a/.github/workflows/CompatHelper.yml b/.github/workflows/CompatHelper.yml new file mode 100644 index 0000000..cba9134 --- /dev/null +++ b/.github/workflows/CompatHelper.yml @@ -0,0 +1,16 @@ +name: CompatHelper +on: + schedule: + - cron: 0 0 * * * + workflow_dispatch: +jobs: + CompatHelper: + runs-on: ubuntu-latest + steps: + - name: Pkg.add("CompatHelper") + run: julia -e 'using Pkg; Pkg.add("CompatHelper")' + - name: CompatHelper.main() + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }} + run: julia -e 'using CompatHelper; CompatHelper.main()' diff --git a/.github/workflows/TagBot.yml b/.github/workflows/TagBot.yml new file mode 100644 index 0000000..f49313b --- /dev/null +++ b/.github/workflows/TagBot.yml @@ -0,0 +1,15 @@ +name: TagBot +on: + issue_comment: + types: + - created + workflow_dispatch: +jobs: + TagBot: + if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot' + runs-on: ubuntu-latest + steps: + - uses: JuliaRegistries/TagBot@v1 + with: + token: ${{ secrets.GITHUB_TOKEN }} + ssh: ${{ secrets.DOCUMENTER_KEY }} diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml new file mode 100644 index 0000000..33acf68 --- /dev/null +++ b/.github/workflows/format.yml @@ -0,0 +1,8 @@ +name: Format suggestions +on: + pull_request: +jobs: + code-style: + runs-on: ubuntu-latest + steps: + - uses: julia-actions/julia-format@v2.0.0 From 04019cdbb16a8bb8c540d210c0d186abcd4ed07c Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:29:37 +0100 Subject: [PATCH 05/17] test --- test/runtests.jl | 1 + test/setup.jl | 2 ++ 2 files changed, 3 insertions(+) create mode 100644 test/runtests.jl create mode 100644 test/setup.jl diff --git a/test/runtests.jl b/test/runtests.jl new file mode 100644 index 0000000..8cc1e62 --- /dev/null +++ b/test/runtests.jl @@ -0,0 +1 @@ +include("setup.jl") \ No newline at end of file diff --git a/test/setup.jl b/test/setup.jl new file mode 100644 index 0000000..edb66a2 --- /dev/null +++ b/test/setup.jl @@ -0,0 +1,2 @@ +using ERPExplorer +using Test From 8b0d22d63676109cbc25db2fc59406b4740f6b6c Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev <33777074+vladdez@users.noreply.github.com> Date: Sat, 7 Dec 2024 21:31:37 +0000 Subject: [PATCH 06/17] Update test/setup.jl Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- test/setup.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/setup.jl b/test/setup.jl index edb66a2..f79e999 100644 --- a/test/setup.jl +++ b/test/setup.jl @@ -1,2 +1,2 @@ using ERPExplorer -using Test +using Test From 06a5c60b4a664104d55e800f15c28ca7dd84ac74 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:49:53 +0100 Subject: [PATCH 07/17] liveserver --- docs/run_liveserver.jl | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 docs/run_liveserver.jl diff --git a/docs/run_liveserver.jl b/docs/run_liveserver.jl new file mode 100644 index 0000000..59db862 --- /dev/null +++ b/docs/run_liveserver.jl @@ -0,0 +1,7 @@ +using LiveServer +servedocs( + skip_dir = joinpath("src", "generated"), + literate_dir = joinpath("literate"), + literate = joinpath("literate"), + foldername = ".", +) \ No newline at end of file From fd1c203230fe006a2a80f28b4826cd41fcbc0a8e Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:54:22 +0100 Subject: [PATCH 08/17] api --- Project.toml | 4 ++++ docs/api.md | 6 ++++++ docs/index.md | 3 +++ 3 files changed, 13 insertions(+) create mode 100644 docs/api.md create mode 100644 docs/index.md diff --git a/Project.toml b/Project.toml index 9bc2d44..8066c42 100644 --- a/Project.toml +++ b/Project.toml @@ -17,8 +17,12 @@ Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" Revise = "295af30f-e4ad-537b-8983-00126c2a3abe" StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" StatsModels = "3eaba693-59b7-5ba5-a881-562e759f1c8d" +Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" TopoPlots = "2bdbdf9c-dbd8-403f-947b-1a4e0dd41a7a" Unfold = "181c99d8-e21b-4ff3-b70b-c233eddec679" UnfoldMakie = "69a5ce3b-64fb-4f22-ae69-36dd4416af2a" UnfoldSim = "ed8ae6d2-84d3-44c6-ab46-0baf21700804" WGLMakie = "276b4fcb-3e11-5398-bf8b-a0c2d153d008" + +[compat] +Test = "1.11.0" diff --git a/docs/api.md b/docs/api.md new file mode 100644 index 0000000..c8e69d9 --- /dev/null +++ b/docs/api.md @@ -0,0 +1,6 @@ +```@autodocs +Modules = [ERPExplorer] +Order = [:function] +``` + +Internally, we use a `PlotConfig` struct to keep track of common plotting options, so that all functions have a similar API. \ No newline at end of file diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000..636b1e3 --- /dev/null +++ b/docs/index.md @@ -0,0 +1,3 @@ +# ERPExplorer Highlights + +# Hello World! \ No newline at end of file From b2f752c452149f3e4df0c4373b425ec0f6db83e2 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sat, 7 Dec 2024 22:55:20 +0100 Subject: [PATCH 09/17] format --- docs/run_liveserver.jl | 2 +- test/setup.jl | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/run_liveserver.jl b/docs/run_liveserver.jl index 59db862..85879e6 100644 --- a/docs/run_liveserver.jl +++ b/docs/run_liveserver.jl @@ -4,4 +4,4 @@ servedocs( literate_dir = joinpath("literate"), literate = joinpath("literate"), foldername = ".", -) \ No newline at end of file +) diff --git a/test/setup.jl b/test/setup.jl index f79e999..d30ce49 100644 --- a/test/setup.jl +++ b/test/setup.jl @@ -1,2 +1,3 @@ using ERPExplorer using Test + From 0e2bf9a6278103aa0b527c7ebc867d30b0adb27f Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sun, 15 Dec 2024 20:36:57 +0100 Subject: [PATCH 10/17] move file --- docs/{ => src}/api.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/{ => src}/api.md (100%) diff --git a/docs/api.md b/docs/src/api.md similarity index 100% rename from docs/api.md rename to docs/src/api.md From 93808a1b7bede362aba17271f0121bde299095b6 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sun, 15 Dec 2024 21:00:21 +0100 Subject: [PATCH 11/17] first real test --- docs/Project.toml | 1 + docs/gen_data.jl | 26 ++++++++++++++++++++++++++ docs/index.md | 3 ++- test/basic.jl | 10 ++++++++++ test/setup.jl | 3 +++ 5 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 docs/gen_data.jl create mode 100644 test/basic.jl diff --git a/docs/Project.toml b/docs/Project.toml index 27a5312..229a826 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -4,5 +4,6 @@ DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" DataFramesMeta = "1313f7d8-7da2-5740-9ea0-a2ca25f37964" DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" +Glob = "c27321d9-0574-5035-807b-f59d2c89b15c" Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306" Unfold = "181c99d8-e21b-4ff3-b70b-c233eddec679" diff --git a/docs/gen_data.jl b/docs/gen_data.jl new file mode 100644 index 0000000..bed79c2 --- /dev/null +++ b/docs/gen_data.jl @@ -0,0 +1,26 @@ +using UnfoldSim, DataFrames, Random +using GeometryBasics +function gen_data() + d1, evts = UnfoldSim.predef_eeg(n_repeats = 120, noiselevel = 25; return_epoched = true) + dataS = permutedims(repeat(d1, 1, 1, 64), (3, 1, 2)) + dataS = dataS .+ rand(dataS) + + evts = insertcols( + evts, + :saccade_amplitude => rand(nrow(evts)) .* 15, + :luminance => rand(nrow(evts)) .* 100, + :contrast => rand(nrow(evts)), + :string => shuffle( + repeat( + ["stringsuperlong", "stringshort", "stringUPPERCASE", "stringEXCITED!!!!"], + outer = div(nrow(evts), 4), + ), + ), + :animal => shuffle(repeat(["cat", "dog"], outer = div(nrow(evts), 2))), + :fruit => shuffle(repeat(["orange", "banana"], outer = div(nrow(evts), 2))), + :color => shuffle(repeat(["black", "white"], outer = div(nrow(evts), 2))), + ) + + positions = rand(Point2f, size(dataS, 1)) + return dataS, evts, positions +end diff --git a/docs/index.md b/docs/index.md index 636b1e3..c9ab412 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,3 +1,4 @@ # ERPExplorer Highlights -# Hello World! \ No newline at end of file +# ERPExplorer.jl allows interactive exploration of regression-ERPs. +# You can switch on and off formula terms, term values, row and column faceting, line colours and style, marker style. \ No newline at end of file diff --git a/test/basic.jl b/test/basic.jl new file mode 100644 index 0000000..d37c0b1 --- /dev/null +++ b/test/basic.jl @@ -0,0 +1,10 @@ +dataS, evts, pos2d = gen_data() +formulaS = @formula(0 ~ 1 + luminance + fruit + animal) +times = range(0, length = size(dataS, 2), step = 1 ./ 100) +model = Unfold.fit(UnfoldModel, formulaS, evts, dataS, times) +_, positions = TopoPlots.example_data() + +@testset "basic test" begin + explore(model; positions = positions) +end + diff --git a/test/setup.jl b/test/setup.jl index d30ce49..d150d60 100644 --- a/test/setup.jl +++ b/test/setup.jl @@ -1,3 +1,6 @@ using ERPExplorer using Test +path = dirname(Base.current_project()) +include(path * "/docs/gen_data.jl") + From b9c004fa7bb6007b4dbb4abd999a49cb85365b63 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev <33777074+vladdez@users.noreply.github.com> Date: Sun, 15 Dec 2024 20:03:14 +0000 Subject: [PATCH 12/17] Update test/basic.jl Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- test/basic.jl | 1 - 1 file changed, 1 deletion(-) diff --git a/test/basic.jl b/test/basic.jl index d37c0b1..c6e1cf1 100644 --- a/test/basic.jl +++ b/test/basic.jl @@ -7,4 +7,3 @@ _, positions = TopoPlots.example_data() @testset "basic test" begin explore(model; positions = positions) end - From cbac519b0bd1229c5fdb3f58fe8280e596c92aa8 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev <33777074+vladdez@users.noreply.github.com> Date: Sun, 15 Dec 2024 20:03:19 +0000 Subject: [PATCH 13/17] Update test/setup.jl Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- test/setup.jl | 1 - 1 file changed, 1 deletion(-) diff --git a/test/setup.jl b/test/setup.jl index d150d60..3e8deed 100644 --- a/test/setup.jl +++ b/test/setup.jl @@ -3,4 +3,3 @@ using Test path = dirname(Base.current_project()) include(path * "/docs/gen_data.jl") - From beddb3cd9c45f8f27c4b87d835fa2ce03a5d5b6e Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sun, 15 Dec 2024 21:06:35 +0100 Subject: [PATCH 14/17] no file --- scripts/gen_data.jl | 26 -------------------------- 1 file changed, 26 deletions(-) delete mode 100644 scripts/gen_data.jl diff --git a/scripts/gen_data.jl b/scripts/gen_data.jl deleted file mode 100644 index bed79c2..0000000 --- a/scripts/gen_data.jl +++ /dev/null @@ -1,26 +0,0 @@ -using UnfoldSim, DataFrames, Random -using GeometryBasics -function gen_data() - d1, evts = UnfoldSim.predef_eeg(n_repeats = 120, noiselevel = 25; return_epoched = true) - dataS = permutedims(repeat(d1, 1, 1, 64), (3, 1, 2)) - dataS = dataS .+ rand(dataS) - - evts = insertcols( - evts, - :saccade_amplitude => rand(nrow(evts)) .* 15, - :luminance => rand(nrow(evts)) .* 100, - :contrast => rand(nrow(evts)), - :string => shuffle( - repeat( - ["stringsuperlong", "stringshort", "stringUPPERCASE", "stringEXCITED!!!!"], - outer = div(nrow(evts), 4), - ), - ), - :animal => shuffle(repeat(["cat", "dog"], outer = div(nrow(evts), 2))), - :fruit => shuffle(repeat(["orange", "banana"], outer = div(nrow(evts), 2))), - :color => shuffle(repeat(["black", "white"], outer = div(nrow(evts), 2))), - ) - - positions = rand(Point2f, size(dataS, 1)) - return dataS, evts, positions -end From 943a0c1a7b13386c73a43c409dac525ed65b088d Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Sun, 15 Dec 2024 21:48:14 +0100 Subject: [PATCH 15/17] some words in index --- docs/Project.toml | 1 + docs/make.jl | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/Project.toml b/docs/Project.toml index 229a826..f148578 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -4,6 +4,7 @@ DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" DataFramesMeta = "1313f7d8-7da2-5740-9ea0-a2ca25f37964" DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" +ERPExplorer = "a0936657-5da6-42c1-a2f2-44cfa89f194c" Glob = "c27321d9-0574-5035-807b-f59d2c89b15c" Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306" Unfold = "181c99d8-e21b-4ff3-b70b-c233eddec679" diff --git a/docs/make.jl b/docs/make.jl index 0c07c91..e879242 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -36,7 +36,7 @@ makedocs(; "ERPExplorer highlights" => "index.md", #"Plotting" => "generated/intro/toposeries.md", #"Diagnostics" => "generated/intro/gnostics.md", - #"API / DocStrings" => "api.md", + "API / DocStrings" => "src/api.md", ], ) From 55f7414692bcadb8827807ff330e4250372205ad Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Fri, 20 Dec 2024 15:28:33 +0100 Subject: [PATCH 16/17] correct directory --- docs/make.jl | 2 +- docs/src/index.md | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 docs/src/index.md diff --git a/docs/make.jl b/docs/make.jl index e879242..426c46c 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -36,7 +36,7 @@ makedocs(; "ERPExplorer highlights" => "index.md", #"Plotting" => "generated/intro/toposeries.md", #"Diagnostics" => "generated/intro/gnostics.md", - "API / DocStrings" => "src/api.md", + "API / DocStrings" => "api.md", ], ) diff --git a/docs/src/index.md b/docs/src/index.md new file mode 100644 index 0000000..c9ab412 --- /dev/null +++ b/docs/src/index.md @@ -0,0 +1,4 @@ +# ERPExplorer Highlights + +# ERPExplorer.jl allows interactive exploration of regression-ERPs. +# You can switch on and off formula terms, term values, row and column faceting, line colours and style, marker style. \ No newline at end of file From cbc0a0d3236261b492dca0c6daa4cd5224e71e66 Mon Sep 17 00:00:00 2001 From: Vladimir Mikheev Date: Fri, 20 Dec 2024 15:52:47 +0100 Subject: [PATCH 17/17] format --- src/formula_extractor.jl | 2 ++ test/runtests.jl | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/formula_extractor.jl b/src/formula_extractor.jl index d5b1336..84e1e59 100644 --- a/src/formula_extractor.jl +++ b/src/formula_extractor.jl @@ -1,4 +1,6 @@ const BSplineTerm = Base.get_extension(Unfold, :UnfoldBSplineKitExt).BSplineTerm + + get_sym(t::InterceptTerm) = "" get_sym(t::AbstractTerm) = t.sym get_sym(t::BSplineTerm) = t.term.sym diff --git a/test/runtests.jl b/test/runtests.jl index 8cc1e62..527755f 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -1 +1 @@ -include("setup.jl") \ No newline at end of file +include("setup.jl")