Re: [Rd] Dropping RHS of a formula using NULL assignment

2021-12-14 Thread Sebastian Meyer
Am 14.12.21 um 21:57 schrieb Prof Brian Ripley: On 14/12/2021 20:26, Blackwell, Matthew wrote: Hello all, In attempting to create a one-sided formula from a two-sided formula, I discovered that the following syntax will successfully complete this operation: f <- y ~ x + z f[2] <- NULL f ~x +

Re: [Rd] Dropping RHS of a formula using NULL assignment

2021-12-14 Thread Prof Brian Ripley
On 14/12/2021 20:26, Blackwell, Matthew wrote: Hello all, In attempting to create a one-sided formula from a two-sided formula, I discovered that the following syntax will successfully complete this operation: f <- y ~ x + z f[2] <- NULL f ~x + z str(f) Class 'formula' language ~x + z .

Re: [Rd] Dropping RHS of a formula using NULL assignment

2021-12-14 Thread Duncan Murdoch
On 14/12/2021 3:26 p.m., Blackwell, Matthew wrote: Hello all, In attempting to create a one-sided formula from a two-sided formula, I discovered that the following syntax will successfully complete this operation: f <- y ~ x + z f[2] <- NULL f ~x + z str(f) Class 'formula' language ~x + z

[Rd] Dropping RHS of a formula using NULL assignment

2021-12-14 Thread Blackwell, Matthew
Hello all, In attempting to create a one-sided formula from a two-sided formula, I discovered that the following syntax will successfully complete this operation: > f <- y ~ x + z > f[2] <- NULL > f ~x + z > str(f) Class 'formula' language ~x + z ..- attr(*, ".Environment")= In searching thro