Displaying 5 results from an estimated 5 matches for "josipovic".
Did you mean:
joksimovic
2018 Feb 15
2
writeLines argument useBytes = TRUE still making conversions
I think this behavior is inconsistent with the documentation:
tmp <- '?'
tmp <- iconv(tmp, to = 'UTF-8')
print(Encoding(tmp))
print(charToRaw(tmp))
tmpfilepath <- tempfile()
writeLines(tmp, con = file(tmpfilepath, encoding = 'UTF-8'), useBytes = TRUE)
[1] "UTF-8"
[1] c3 a9
Raw text as hex: c3 83 c2 a9
If I switch to useBytes = FALSE, then
2018 Feb 15
2
writeLines argument useBytes = TRUE still making conversions
...e, it sounds like translation should be suppressed at both steps.
>
> I think this is documented correctly in ?writeLines (and also the
> Encoding section of ?file), but the behavior may feel unfamiliar at
> first glance.
>
> Kevin
>
> On Wed, Feb 14, 2018 at 11:36 PM, Davor Josipovic <davorj at live.com> wrote:
>>
>> I think this behavior is inconsistent with the documentation:
>>
>> tmp <- '?'
>> tmp <- iconv(tmp, to = 'UTF-8')
>> print(Encoding(tmp))
>> print(charToRaw(tmp))
>> tmpfilepath &...
2018 Feb 15
0
writeLines argument useBytes = TRUE still making conversions
...assed to the connection.
In your case, it sounds like translation should be suppressed at both steps.
I think this is documented correctly in ?writeLines (and also the
Encoding section of ?file), but the behavior may feel unfamiliar at
first glance.
Kevin
On Wed, Feb 14, 2018 at 11:36 PM, Davor Josipovic <davorj at live.com> wrote:
>
> I think this behavior is inconsistent with the documentation:
>
> tmp <- '?'
> tmp <- iconv(tmp, to = 'UTF-8')
> print(Encoding(tmp))
> print(charToRaw(tmp))
> tmpfilepath <- tempfile()
> writeLine...
2018 Feb 17
1
writeLines argument useBytes = TRUE still making conversions
....
>>>
>>> I think this is documented correctly in ?writeLines (and also the
>>> Encoding section of ?file), but the behavior may feel unfamiliar at
>>> first glance.
>>>
>>> Kevin
>>>
>>> On Wed, Feb 14, 2018 at 11:36 PM, Davor Josipovic <davorj at live.com> wrote:
>>>>
>>>> I think this behavior is inconsistent with the documentation:
>>>>
>>>> tmp <- '?'
>>>> tmp <- iconv(tmp, to = 'UTF-8')
>>>> print(Encoding(tmp))
>>&...
2018 Feb 17
0
writeLines argument useBytes = TRUE still making conversions
...ould be suppressed at both steps.
>>
>> I think this is documented correctly in ?writeLines (and also the
>> Encoding section of ?file), but the behavior may feel unfamiliar at
>> first glance.
>>
>> Kevin
>>
>> On Wed, Feb 14, 2018 at 11:36 PM, Davor Josipovic <davorj at live.com> wrote:
>>>
>>> I think this behavior is inconsistent with the documentation:
>>>
>>> tmp <- '?'
>>> tmp <- iconv(tmp, to = 'UTF-8')
>>> print(Encoding(tmp))
>>> print(charToRaw(tm...