Hi,

I'll split the issues, and reply to the last one, first.

On Monday 07 February 2011, meik michalke wrote:
> > some.data <- data.frame(a=c("a","b","c","d"))
[...]
> > some.data$a
> 
> [1] a b c d
> Levels: a b c d
> 
> so "a" was converted to a factor. then open "some.data" in the editor
> component and change the type of column "a" from "factor" to "strings". now
> 
> look at the object in the R console:
[...]
> > some.data$a
> 
> [1] "1" "2" "3" "4"
> attr(,"levels")
> [1] "a" "b" "c" "d"
> attr(,".rk.invalid.fields")
> list()
>
> this is not really what i expect of the conversion to "string".

Indeed. Fixed.

> i was first
> surprised that the editor still shows factor levels

Yes, the idea was to support "value labels" on data types other than factors, 
similar to e.g. SPSS. Think of likert-scales for a use case where data is 
"numeric" (not in IRT, of course), but end-points are named. Of course, since 
factor levels can only be assigned to consecutive integers, this does not work 
too well. Perhaps a feature worth removing? What do you think?

> , and even though type
> says "string" you cannot remove those levels safely.

True. But that was just a side-effect of the conversion problem, above. I.e. 
that should be fixed, too.

> in fact, this doesn't
> work in
> 
> RKWard either:
> > some.data <- data.frame(a=c("a","b","c","d"), stringsAsFactors=FALSE)
[...]
> > some.data$a
> 
> [1] "1" "2" "3" "4"

I could not reproduce this, and we really don't mess with data.frame() on this 
level. Are you sure?

Regards
Thomas

Attachment: signature.asc
Description: This is a digitally signed message part.

------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
RKWard-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rkward-devel

Reply via email to