[New Features on steemr] Functions for accounts and comments report!

in #utopian-io6 years ago (edited)

Repo

https://github.com/pzhaonet/steemr

'steemr' is an open source R package for playing with Steem data in R environment. It is used to download, post process, analyze, and visualize Steem data on the basis of the powerful statistic power of R.

New Features

What features did I add?

New functions were added to the steemr pakcage, which now can retrieve the account data and the comment data and plot diagrams automatically.

  • gaccounts() retrieves the account data from the server, makes a summary of the account data, and plots a time series of the daily new accounts automatically.

Here is an example, showing the daily new steem accounts in a diagram and a table from 2018/01/01 to 2018/07/01 produced by gaccounts() :

gaccounts.jpeg

          date  Freq
1   2017-12-31  1161
2   2018-01-01  1397
3   2018-01-02  8638
4   2018-01-03  6901
5   2018-01-04  2660
6   2018-01-05  7979
7   2018-01-06  4940
8   2018-01-07  8391
9   2018-01-08  4340
10  2018-01-09  5122
...
178 2018-06-26   545
179 2018-06-27   460
180 2018-06-28   405
181 2018-06-29   376
182 2018-06-30   353
183 2018-07-01   321
  • gcomments() retrieves the comment data from the server, makes a summary of the comment data, and plots a time series of the daily comments of a given ID automatically.

Here is an example , showing the daily comments (posts and replies) of my own in a diagram and a table produced by gcomments() :

gcomments.jpeg

        date Freq
1 2017-07-17    9
2 2017-07-18    3
3 2017-07-19    8
4 2017-07-20    9
5 2017-07-21    1
6 2017-07-22    4
...
311 2018-06-27   10
312 2018-06-28   10
313 2018-06-29    3
314 2018-06-30    4
315 2018-07-01   15
316 2018-07-02   10

These main functions are supported by some other functions:

  • adailyf(), which produces a daily summary and a daily diagram from a give data set,
  • pdate() and xatf(), which were tailored to plot time series of Steem data.

The old functions were renamed for better understanding. The meaning of the beginning letter in a function name:

  • a: analysis
  • g: get data
  • p: plot a diagram

The script files were re-organized, according to the functions.

Some minor literal changes and small bugs were fixed as well.

How did I implement them?

I split the former 'R/steemr.R' into 'R/plothour.r', 'R/analysis.r', and 'R/get.r'.

I created new scripts 'R/internal.r' for internal used function, 'R/plot.r' for plotting functions, and 'R/import.r' for importing some external packages

I added the new functions into 'R/plot.r', 'R/analysis.r' and 'R/get.r'

Links to relevant lines in the code on GitHub can be found mainly in my latest commits (click to see the details):

GitHub Account

https://github.com/pzhaonet

Sort:  

@dapeng You have received a 100% upvote from @looktothefuture because this post did not use any bidbots and you have not used bidbots in the last 30 days!

Upvoting this comment will help keep this service running.

Thanks! I have never used any bidbots since I came here. I will never. You are invited to my every single post in the future.

I haven't used bidbots in the last 30 days either.

Thank you for your contribution. As a public and free library, I wouldn't recommend adding features that require paid service, in this case, the @steemsql . I can see you have implemented some functions using steemsql e.g. the gacounts method.

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]

I can't change the direction of the wind, but I can adjust my sails to always reach my destination.

@cryptoindex self votes are being countered by @sadkitten for 1 week starting Thursday, June 28th 2018, 3:57 because they are one of the highest self voters of the previous week. For more details see this post.

大鹏哥哥,我想发起一个好文活动,https://shimo.im/docs/XNDhqU0vmV45eltd 希望能得到大鹏哥哥的指点

指点我可不敢当……文案写得很好,又发现一枚三体迷!

大鹏哥哥也喜欢三体嘛,开心😄我可以邀请大鹏哥哥做评委嘛,很需要你

谢谢邀请!很抱歉,最近我在忙搬家,没有余暇,评委的机会留给别人吧。多谢!

大鹏,我发布了一个活动,希望得到您的支持!!【CN区美食大赛#1】—我们的味蕾需要你【美食-鱼】 | [CN District Food Contest] - Our taste buds need you [Gourmet-Fish],如果可以的话,也希望您也来参加!!谢谢!

支持支持!口水都要流出来 了

谢谢大鹏的支持,您也来参加吧!!哈哈哈!

Hey @dapeng
Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

Coin Marketplace

STEEM 0.19
TRX 0.15
JST 0.029
BTC 63252.26
ETH 2662.75
USDT 1.00
SBD 2.79