将 data.frame 列格式从字符转换为因子
作者:Rasoul 提问时间:2/13/2012
我想将我的 data.frame 对象 () 的某些列的格式(类)从字符更改为因子。mydf 当我按功能读取文本文件时,我不想这样做。read.table() 任何帮助将不胜感激。...
-FAQ 问答列表
作者:Rasoul 提问时间:2/13/2012
我想将我的 data.frame 对象 () 的某些列的格式(类)从字符更改为因子。mydf 当我按功能读取文本文件时,我不想这样做。read.table() 任何帮助将不胜感激。...
作者:Gal Goldman 提问时间:12/17/2008
在 C++ 中,我想不出我想从 基类: class Base; class Derived1 : private Base; class Derived2 : protected Base; 它...
作者:Btibert3 提问时间:11/30/2010
我有一个数据框,其中包含日期时间的字符列。 当我使用 时,除了少数实例外,我的大多数字符串都被正确解析。下面的例子希望能告诉你发生了什么。as.Date # my attempt to parse...
作者:David LeBauer 提问时间:12/15/2010
使用我编写的 R 函数时出现错误: Warning messages: 1: glm.fit: algorithm did not converge 2: glm.fit: algorithm d...
作者:Richie Cotton 提问时间:1/13/2015
如果我想检查变量是否继承自某个类,我可以使用 is 或 inherits。 class(letters) ## [1] "character" is(letters, "character") ##...
作者:Mehper C. Palavuzlar 提问时间:2/18/2010
R 中有一个选项可以控制数字显示。例如: options(digits=10) 应该以 10 位数字给出计算结果,直到 R 会话结束。在 R 的帮助文件中,digits 参数的定义如下: 位数...
作者:Frankomania 提问时间:11/8/2008
在 c++ 中,什么是对象切片,它何时发生?...
作者:David Manheim 提问时间:12/25/2012
我有一个纬度和经度值列表,我正在尝试找到它们之间的距离。使用标准的大圆方法,我需要找到: acos(sin(lat1)*sin(lat2) + cos(lat1)*cos(lat2) * cos(l...
作者:Christopher DuBois 提问时间:7/23/2009
假设我有以下向量: x <- c(8, 6, 9, 9, 7, 3, 2, 5, 5, 1, 6, 8, 5, 2, 9, 3, 5, 10, 8, 2) 如何找到哪些元素是 8 或 9?...
作者:Kevin 提问时间:9/23/2008
为什么运算符返回的结构大小大于结构成员的总大小?sizeof...