Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having dimensions without names #90

Open
nalimilan opened this issue May 28, 2020 · 1 comment
Open

Having dimensions without names #90

nalimilan opened this issue May 28, 2020 · 1 comment

Comments

@nalimilan
Copy link
Contributor

By default the constructor uses A, B, etc. for the names of dimensions. AFAICT there is no way to avoid having a name at all. Would it be possible to use nothing for this? Currently it's accepted, but it still prints nothing:

julia> NamedArray(rand(2, 3), [1:2, 1:3], [nothing, nothing])
2×3 Named Array{Float64,2}
nothing ╲ nothing │        1         2         3
──────────────────┼─────────────────────────────
1                 │ 0.974647  0.607695  0.814261
2                 │ 0.458673  0.327957  0.734594

Maybe this could even be the default, as it doesn't sound very useful to generate arbitrary names. FWIW, R doesn't print anything when dimension names are NULL.

@davidavdav
Copy link
Owner

Yes this would make sense. Of course for now you can name your dimensions all ""

Also, it should be possible to have only named indexes for a subset of all dimensions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants