Displaying 4 results from an estimated 4 matches for "c46441".
2017 Jun 26
2
Odd behaviour in within.list() when deleting 2+ variables
...;>> peter dalgaard <pdalgd at gmail.com>
>>>>> on Mon, 26 Jun 2017 13:43:28 +0200 writes:
> This seems to be due to changes made by Martin Maechler in
> 2008. Presumably this fixed something, but it escapes my
> memory.
Yes: The change set (svn -c46441) also contains the following NEWS entry
BUG FIXES
o within(<dataframe>, { ... }) now also works when '...' removes
more than one column.
> However, it seems to have broken the equivalence
> between within.list and within.data.frame, so now
> wi...
2017 Jun 26
0
Odd behaviour in within.list() when deleting 2+ variables
...lgaard <pdalgd at gmail.com>
>>>>>> on Mon, 26 Jun 2017 13:43:28 +0200 writes:
>
>> This seems to be due to changes made by Martin Maechler in
>> 2008. Presumably this fixed something, but it escapes my
>> memory.
>
> Yes: The change set (svn -c46441) also contains the following NEWS entry
>
> BUG FIXES
>
> o within(<dataframe>, { ... }) now also works when '...' removes
> more than one column.
>
The odd thing is that the assign-NULL technique used for removing a single column, NOW also seems to work...
2017 Jun 26
1
Odd behaviour in within.list() when deleting 2+ variables
...>>>>>>> 2017 13:43:28 +0200 writes:
>>
>>> This seems to be due to changes made by Martin Maechler
>>> in 2008. Presumably this fixed something, but it escapes
>>> my memory.
>>
>> Yes: The change set (svn -c46441) also contains the
>> following NEWS entry
>>
>> BUG FIXES
>>
>> o within(<dataframe>, { ... }) now also works when '...'
>> removes more than one column.
>>
> The odd thing is that the assign-NULL techni...
2017 Jun 26
2
Odd behaviour in within.list() when deleting 2+ variables
The behaviour of within() with list input changes if you delete 2 or more variables, compared to deleting one:
l <- list(x=1, y=2, z=3)
within(l,
{
rm(z)
})
#$x
#[1] 1
#
#$y
#[1] 2
within(l, {
rm(y)
rm(z)
})
#$x
#[1] 1
#
#$y
#NULL
#
#$z
#NULL
When 2 or more variables are deleted, the list entries are instead set to NULL. Is this intended?