From h@wickh@m @ending from gm@il@com  Thu Aug  9 16:30:38 2018
From: h@wickh@m @ending from gm@il@com (Hadley Wickham)
Date: Thu, 9 Aug 2018 09:30:38 -0500
Subject: [Rd] vctrs: a type system for the tidyverse
In-Reply-To: <CAO1zAVbutLaTFbL5BM8kgv2Lo7VVYVkYoCxC-YQwDR+ptGkjRA@mail.gmail.com>
References: <CABdHhvFARmiExcEk=NUjfPcRtYnoF4pAA5WTws6r1C+X76zHEw@mail.gmail.com>
 <CAMFmJsn_wNxuV2SQqUiZroJYV+rHRKdADi8Fjg8fRjJr0RGuwQ@mail.gmail.com>
 <CABdHhvEAV-bhprxVMHF_R8vKdN3VEriV86kGNNU02RiK=+m4dQ@mail.gmail.com>
 <CABdHhvHw+_sFcD3H92KQhvurxC8eAyR2A0frZUk7pBcOaVB2Hw@mail.gmail.com>
 <23403.4648.841262.201573@stat.math.ethz.ch>
 <CAMFmJs=hHXYdkd-2kRH48sxB5VJAO4g5Rs35einXs8GwQJ7C8g@mail.gmail.com>
 <CALEXWq2J-J5obavQ=dpkHJmqpt9WQ5a3uZS7L6gY-Fs4X_AuNg@mail.gmail.com>
 <CAO1zAVbaB9fmtrFFYLuusm2jOyh1SHQnDm3U8vjFPNiitk=+hw@mail.gmail.com>
 <CABdHhvH9Xo-W3gj7Sk+htfa9uzVLhWZSmk_mP+o6BoaFub=1hQ@mail.gmail.com>
 <CAO1zAVbutLaTFbL5BM8kgv2Lo7VVYVkYoCxC-YQwDR+ptGkjRA@mail.gmail.com>
Message-ID: <CABdHhvG=Gogpa8ZPQAKcrVeQtZoAEiWJezB=k46LL90K65-VHQ@mail.gmail.com>

On Thu, Aug 9, 2018 at 7:54 AM Joris Meys <jorismeys at gmail.com> wrote:
>
> Hi Hadley,
>
> my point actually came from a data analyst point of view. A character variable is something used for extra information, eg the "any other ideas?" field of a questionnaire. A categorical variable is a variable describing categories defined by the researcher. If it is made clear that a factor is the object type needed for a categorical variable, there is no confusion. All my students get it. But I agree that in many cases people are taught that a factor is somehow related to character variables. And that does not make sense from a data analyst point of view if you think about variables as continuous, ordinal and nominal in a model context.
>
> So I don't think adding more confusing behaviour and pitfalls is a solution to something that's essentially a misunderstanding. It's something that's only solved by explaining it correctly imho.

I agree with your definition of character and factor variables. It's
an important distinction, and I agree that the blurring of factors and
characters is generally undesirable. However, the merits of respecting
R's existing behaviour, and Martin M?chler's support, means that I'm
not going to change vctr's approach at this point in time. However, I
hear from you and Gabe that this is an important issue, and I'll
definitely keep it in mind as I solicit further feedback from users.

Hadley

-- 
http://hadley.nz



[Rd] vctrs: a type system for the tidyverse
Hadley Wickham