What does “data.table” “data.frame” class mean?

会有一股神秘感。 提交于 2020-01-16 16:11:18

问题


I am running data.frames through an analysis that takes around 45 minutes to complete. I recently began working with a new data set with similar content and (I thought) similar structure, but found that it was taking exponentially longer to analyze and producing errors that made it evident that there were structural differences.

Looking at attributes, I found that it was $class "data.table" "data.frame". Running as.dataframe() seems to have converted it to just "data.frame", and processing time seems to be normal.

Saving the question of how I created this class in the first place (I assume something to do with a clumsy extraction of a nested data.frame) for another time, could someone with a bit more depth in the subject than I have please explain what "data.table" "data.frame" actually means?

Everything I've been able to find makes them sound mutually exclusive, and I wouldn't expect the $class field to return the sub-class of objects within x, when looking at attributes(x).

来源:https://stackoverflow.com/questions/49659969/what-does-data-table-data-frame-class-mean

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!