Skip to content

plot_designmatrix fails for small designmatrices #274

Open
@behinger

Description

Describe the bug
plot_designmatrix fails for small designmatrices

Code To Reproduce

using Unfold,UnfoldMakie,CairoMakie
data, evts = UnfoldSim.predef_eeg(sfreq = 5, n_repeats = 1)

basisfunction = firbasis(τ = (-1, 2), sfreq = 5, scale_duration = true)

f = @formula 0 ~ 1 + condition

bf_vec = [Any => (f, basisfunction)]
m = fit(UnfoldModel, bf_vec, evts, data; eventfields = [:latency, :duration]);

heatmap(Matrix(modelmatrix(m))')
plot_designmatrix(designmatrix(m))

Expected behavior
the plots show up.

Versions:

  • Julia: 1.11.1
  • UnfoldMakie: 0.5.9

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions