Skip to content

Fixed() error #125

Closed
Closed
@valentinkm

Description

@valentinkm

Fixed type not recognized as a subtype of Number in the JudgementNumber and JudgementVecNumber types.

  1. StandaloneFactor(n_variables = 6, factor_variance = Fixed(1.0), loadings = missing, quest_scale = 7)
    raises:
    """
    ERROR: TypeError: in JudgementNumber, in T, expected T<:(Union{Missing, var"#s21"} where var"#s21"<:Number), got Type{Fixed{Float64}}
    Stacktrace:
    [1] JudgementNumber(r::Fixed{Float64}, c::Float64, l::Missing) (repeats 2 times)
    @ Taxonomy.Judgements ~/.julia/packages/Taxonomy/SLRyy/src/judgements/judgement.jl:52
    [2] convert
    @ ~/.julia/packages/Taxonomy/SLRyy/src/judgements/judgement.jl:133 [inlined]
    [3] Measurement
    @ ~/.julia/packages/Taxonomy/SLRyy/src/taxons/measurement.jl:35 [inlined]
    [4] #Measurement#8
    @ ~/.julia/packages/Taxonomy/SLRyy/src/taxons/measurement.jl:68 [inlined]
    [5] #StandaloneFactor#9
    @ ~/.julia/packages/Taxonomy/SLRyy/src/taxons/measurement.jl:89 [inlined]
    [6] top-level scope
    @ ~/Desktop/Literature-Research-Pilot/DB_extended_judgements.jl:389
    """

  2. :SSB => Measurement(n_variables = 3, factor_variance = missing, loadings = [Fixed(1), 0.98, 0.92], quest_scale = 4)
    raises:
    """
    ERROR: TypeError: in JudgementVecNumber, in T, expected T<:(Union{Missing, var"#s21"} where var"#s21"<:(Vector{<:Union{Missing, Number}})), got Type{Vector{Any}}
    Stacktrace:
    [1] JudgementVecNumber(r::Vector{Any}, c::Float64, l::Missing) (repeats 2 times)
    @ Taxonomy.Judgements ~/.julia/packages/Taxonomy/SLRyy/src/judgements/judgement.jl:52
    [2] convert
    @ ~/.julia/packages/Taxonomy/SLRyy/src/judgements/judgement.jl:133 [inlined]
    [3] Measurement
    @ ~/.julia/packages/Taxonomy/SLRyy/src/taxons/measurement.jl:35 [inlined]
    [4] #Measurement#8
    @ ~/.julia/packages/Taxonomy/SLRyy/src/taxons/measurement.jl:68 [inlined]
    [5] top-level scope
    @ ~/Desktop/Literature-Research-Pilot/DB_extended_judgements.jl:346
    """

Metadata

Metadata

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