我有一個describe.by {psych}應用於數據框的結果。結果是一個列表。 List of 1000
$ 1 :Classes ‘psych’, ‘describe’ and 'data.frame': 20 obs. of 13 variables:
..$ var : int [1:20] 1 2 3 4 5 6 7 8 9 10 ...
..$ n : nu
我正在使用DataMapper進行數據庫訪問。我的目標是將模型作爲只讀對象發送到Web服務。這是我目前的嘗試: class User
include DataMapper::Resource
def to_yaml(opts = {})
mini_me = OpenStruct.new
instance_variables.each do |var|