Skip to content

Missing methods in diagind documentation #1469

@Luis-Varona

Description

@Luis-Varona

The diagind documentation only covers the

diagind(M::AbstractMatrix, k::Integer = 0, indstyle::IndexStyle = IndexLinear())
diagind(M::AbstractMatrix, indstyle::IndexStyle = IndexLinear())

methods requiring the full input matrix. However, there also exist the methods

diagind(m::Integer, n::Integer, k::Integer=0)
diagind(::IndexLinear, m::Integer, n::Integer, k::Integer=0)

only requiring the matrix dimensions, which may prove useful in some cases as pointed out in #1460 by @RoyiAvital. I propose that these methods be added to the corresponding documentation, with examples such as

julia> diagind(5, 7)
1:6:25

julia> diagind(5, 7, 2)
11:6:35

being provided as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions