From p@u|@buerkner @end|ng |rom gm@||@com  Mon Aug  5 21:44:23 2019
From: p@u|@buerkner @end|ng |rom gm@||@com (Paul Buerkner)
Date: Mon, 5 Aug 2019 21:44:23 +0200
Subject: [Rd] Potential bug in update.formula when updating offsets
Message-ID: <CAGoSky9QAyfxW6bxzkVACQGX95SR2H-9rt2H2+EnF_Db_tDcLg@mail.gmail.com>

Hi all,

update.formula does not seem to correctly update (i.e. remove in my case)
offset terms.

Here is an example:

update(~x + offset(z), ~ . - offset(z))
> ~x + offset(z)

Also:
update(~x, ~ . - offset(z))
> ~x + offset(z)

In both cases, I would expect the result
> ~x

as  - <term>  should remove <term> from the formula as happens for instance
in:

update(~x + z, ~ . - z)
> ~x

I don't know if this behavior is intentional but I would say it is at least
unfortunate.

Paul

	[[alternative HTML version deleted]]



[Rd] Potential bug in update.formula when updating offsets
Paul Buerkner