🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

"writing csv files, booleans should be 0 and 1"

User: "wessel"
New Altair Community Member
Updated by Jocelyn
Dear All,

How to write a .csv file with Boolean values as 1's and 0's.
Currently it writes out "true" and "false".

Best regards,

Wessel

Find more posts tagged with

Sort by:
1 - 3 of 31
    User: "Nils_Woehler"
    New Altair Community Member
    Hi,

    you can use a Generate Attributes to create an attribute which contains 1 in case of true and 0 in case of false. Then remove your old attribute
    and rename the created one to your desired name.

    Best,
    Nils
    User: "wessel"
    New Altair Community Member
    OP
    Hey Nils,

    Thanks.

    So basically what your saying is.
    Create numeric attributes.
    (Numeric attributes write 0.0 and 1.0 by the way).

    Or should I use "1" and "0" in string value?
    To create a nominal attribute?
    I guess that would really write out what I was asking for.

    Best regards,

    Wessel
    User: "Nils_Woehler"
    New Altair Community Member
    I would recommend you to create a nominal attribute as numerical attributes probably get written as 1.0 etc. :-)
    With a nominal attribute with values "1" and "0" it should write if you have unchecked the "quote nominal values" option.

    Best,
    Nils