I'm looking to build a Rails app to do internal reporting (make charts or general data visualizations, create reports, show statistical analyses, etc.) on data my company collects.
我正在构建一个Rails应用程序来对我的公司收集的数据进行内部报告(制作图表或通用数据可视化、创建报告、显示统计分析等)。
What would be helpful in building this? For example, any Rails/Javascript libraries I should be familiar with, or any open source analytics apps or existing dashboard tools I should look at?
什么会有助于建立这个?例如,我应该熟悉的任何Rails/Javascript库,或者我应该查看的任何开源分析应用程序或现有仪表板工具?
3 个解决方案
#1
2
Google Visualization API is an easy way to get charts in your application. You could also have a look at Protovis and possibly InfoVis Toolkit.
谷歌可视化API是在应用程序中获取图表的一种简单方法。你也可以看看神族或者InfoVis工具包。
#2
1
I'm actually doing almost the exact same thing right now, so I know what you are going through. For ruby on rails, there's a gem out there called Garb. So far it has worked pretty well for me. Example:
实际上我现在做的是同样的事情,所以我知道你要做什么。对于ruby on rails来说,有一个叫做Garb的gem。到目前为止,它对我来说还不错。例子:
results = []
Garb::Session.login(analytics_email_address, analytics_password)
web_properties = Garb::Profile.all #you can filter here with a clojure or something
for profile in web_properties
report = Garb::Report.new(profile, start_date, end_date)
report.metrics MY_METRICS #you can read about these on the analytics api docs
report.dimensions MY_DIMENSIONS #same here
results << report.results
end
#do more stuff
This is a simple/quick/dirty example, but it works; you can get the information you need about the metrics and dimensions here:
这是一个简单/快速/肮脏的例子,但是它是有效的;您可以在这里获得关于度量和维度所需的信息:
http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html
http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html
and Garb information here:
和服装信息:
http://www.viget.com/extend/introducing-garb-access-the-google-analytics-data-export-api-with-ruby/
http://www.viget.com/extend/introducing-garb-access-the-google-analytics-data-export-api-with-ruby/
I know that reporting is really frustrating, so I wish you the best of luck!
我知道报道很令人沮丧,所以我祝你好运!
#3
1
Don 't forget to create summaries of your data if you have lots of data. For example calculate all pageviews for a single day and store them in a Day table or so. Otherwise your app will become very unresponsive. Dont forget that Ruby 1.8 sucks for stats and math (slow)
如果你有大量的数据,不要忘记创建你的数据摘要。例如,计算一天的所有页面视图,并将它们存储在一个日表中。否则你的应用会变得非常迟钝。别忘了Ruby 1.8在统计和数学上很烂(慢)
#1
2
Google Visualization API is an easy way to get charts in your application. You could also have a look at Protovis and possibly InfoVis Toolkit.
谷歌可视化API是在应用程序中获取图表的一种简单方法。你也可以看看神族或者InfoVis工具包。
#2
1
I'm actually doing almost the exact same thing right now, so I know what you are going through. For ruby on rails, there's a gem out there called Garb. So far it has worked pretty well for me. Example:
实际上我现在做的是同样的事情,所以我知道你要做什么。对于ruby on rails来说,有一个叫做Garb的gem。到目前为止,它对我来说还不错。例子:
results = []
Garb::Session.login(analytics_email_address, analytics_password)
web_properties = Garb::Profile.all #you can filter here with a clojure or something
for profile in web_properties
report = Garb::Report.new(profile, start_date, end_date)
report.metrics MY_METRICS #you can read about these on the analytics api docs
report.dimensions MY_DIMENSIONS #same here
results << report.results
end
#do more stuff
This is a simple/quick/dirty example, but it works; you can get the information you need about the metrics and dimensions here:
这是一个简单/快速/肮脏的例子,但是它是有效的;您可以在这里获得关于度量和维度所需的信息:
http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html
http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html
and Garb information here:
和服装信息:
http://www.viget.com/extend/introducing-garb-access-the-google-analytics-data-export-api-with-ruby/
http://www.viget.com/extend/introducing-garb-access-the-google-analytics-data-export-api-with-ruby/
I know that reporting is really frustrating, so I wish you the best of luck!
我知道报道很令人沮丧,所以我祝你好运!
#3
1
Don 't forget to create summaries of your data if you have lots of data. For example calculate all pageviews for a single day and store them in a Day table or so. Otherwise your app will become very unresponsive. Dont forget that Ruby 1.8 sucks for stats and math (slow)
如果你有大量的数据,不要忘记创建你的数据摘要。例如,计算一天的所有页面视图,并将它们存储在一个日表中。否则你的应用会变得非常迟钝。别忘了Ruby 1.8在统计和数学上很烂(慢)