[Piston] Who are your followers
Who are your followers
Sounds simple isn't it?
Thanks to @jesta we have now links available in the profile page. Let's find the same information out using Python, @xeroc's steem-piston and graphene followers API.
I implemented a small experiment:
import sys
from steemapi.steemnoderpc import SteemNodeRPC
class FollowMe(object):
def __init__(self):
self.rpc = SteemNodeRPC("wss://node.steem.ws", "", "", apis=["follow"])
def followers(self, account):
return [ f['follower'] for f in self.rpc.get_followers(account, "", "blog", 100, api="follow") ]
if __name__ == '__main__':
if len(sys.argv) < 2:
sys.stderr.write("Usage: %s steem_account" % (sys.argv[0],))
sys.exit(1)
f = FollowMe()
print("%s followers %s" % (sys.argv[1], f.followers(sys.argv[1])))
and run it against my STEEM account:
$ python3 followers.py cryptomental
cryptomental followers ['alexoz', 'ausbitbank', 'feedthemachine', 'kenny-crane', 'omarb', 'steemlinks']
Hmm... I just have 6 followers :( hopefully this will change in the future...
Who are you following
The following API let's you see people who you are following. Two more lines will be enough:
def following(self, account):
return [ f['following'] for f in self.rpc.get_following(account, "", "blog", 100, api="follow") ]
Well you know who are you following, don't you? ;-)
$ python3 followers.py cryptomental
cryptomental followers ['alexoz', 'ausbitbank', 'feedthemachine', 'kenny-crane', 'omarb', 'steemlinks']
cryptomental follows ['jesta', 'xeroc']
Now something more difficult: meet people who are following your followers
for follower in f.followers(sys.argv[1]):
print("%s is followed by %s" % (follower, f.followers(follower)))
print(60*"-")
and there it goes...
alexoz is followed by ['ab94', 'acarya', 'adolphius', 'akaninyene-etuk', 'alexgr', 'alitas', 'allmonitors', 'andre-ager', 'anotherjoe', 'antyivan', 'anxietymaven', 'ashwim', 'augustinsong', 'barrydutton', 'bdavid', 'beanz', 'ben99', 'benjy33', 'beowulfoflegend', 'bhavnapatel68', 'bitcoinfly', 'bitland', 'bluestar', 'brindleswan', 'christiansenn', 'cian.dafe', 'clevecross', 'cogliostro', 'condra', 'cousteau', 'crowfromwithin', 'cryptoiskey', 'cryptojoy.com', 'dave-hughes', 'daveks', 'davidmlesley', 'daycrypter', 'derekareith', 'digitalhound', 'djbfrank', 'djm34', 'dumar022', 'e-steem', 'edtorrez', 'elissahawke', 'erotic', 'felixxx', 'foxkoit', 'freedomengineer', 'frol', 'funkywanderer', 'georgina', 'haley-liz', 'heretickitten', 'herzmeister', 'hien-tran', 'hilarski', 'iamrohitkgupta', 'imtiaz', 'inertia', 'inkha', 'iseektruth', 'ivanba12', 'jasmine-l', 'jaysanz', 'jbouchard12', 'jeffereyjaxen', 'jeison', 'jevgenz', 'jonno-katz', 'joseph', 'karchersmith', 'karenb54', 'kendewitt', 'kingsjack123', 'kirby1', 'kreativ', 'kristina011891', 'kus-knee', 'lantto', 'leksimus', 'lescraig', 'loum', 'lovejoy', 'luke490', 'madhatting', 'magicmonk', 'markrmorrisjr', 'matherly', 'matrioshka', 'mazi', 'michaelelliot', 'mickbynes', 'minergate123', 'miscreantpie', 'mister-t', 'moon32walker', 'moonjelly', 'mrlakmini', 'mrwang']
------------------------------------------------------------
feedthemachine is followed by ['bitmaxt', 'cian.dafe', 'digitalhound', 'edtorrez', 'freedomengineer', 'harveywoods', 'hoffmabc', 'inkha', 'ivanba12', 'michaeldodridge', 'repholder', 'rossenpavlov', 'steemlinks', 'steemzine']
------------------------------------------------------------
omarb is followed by ['achim86', 'alexgr', 'amdnoob', 'andrew0', 'ben99', 'blankslatetheory', 'bonapartist', 'cian.dafe', 'clevecross', 'dahaz159', 'damianquestiny', 'damirkatusic', 'deeallen', 'derekareith', 'digitalhound', 'dimitarj', 'disofdis', 'djmagrobel', 'edtorrez', 'el-huleb', 'frol', 'fyrstikken', 'infosounds', 'inkha', 'ivanba12', 'ivp', 'jbouchard12', 'kanabis420pm', 'kareemaudi', 'kevinwong', 'kristina011891', 'kyriacos', 'localconcierge', 'mohammedouazi', 'naturalista', 'omarbitcoin', 'ossama-benjohn', 'pabich', 'penguinpablo', 'powercouple', 'pupa', 'ridji', 'romaan-namoor', 'romanskv', 'royaltiffany', 'seymour', 'shawn-brewer', 'simo9445', 'sonyanka', 'steemlinks', 'steemzine', 'stino-san', 'teddybrown', 'toonns38', 'usnewspress', 'xenadu']
------------------------------------------------------------
steemlinks is followed by ['ab94', 'abdosenni', 'aboundlessworld', 'achim86', 'adamt', 'adsactly', 'ajaub1962', 'ajavajive', 'alekschm', 'alexft', 'alexgr', 'alexoz', 'alitas', 'all-of-us', 'almiller', 'alsprinting', 'always1success', 'amanarchymartin', 'andre-ager', 'andre62', 'andressilvera', 'anduweb', 'antyivan', 'anwar78', 'apollojae', 'applecrisp', 'argsolver', 'arnoldz61', 'arta.rajabi', 'augustinsong', 'avemend', 'baro', 'barrydutton', 'bbrewer', 'bdavid', 'beanz', 'ben99', 'benadapt', 'benjiberigan', 'bhavnapatel68', 'billjam56', 'bitcoin3d', 'bitcoinmoney', 'bitland', 'bitmaxt', 'bitshares101', 'blackeyed', 'blindleaf', 'blockcodes', 'blueciruit', 'bluestar', 'bmcv001', 'bodhi.agora', 'bones', 'bones261', 'booja', 'breathe3000', 'breck0882', 'bttgh', 'bullionstackers', 'bythenumbers432', 'canadian-coconut', 'cardsanarchy', 'carpenterlogan', 'cccmar71', 'chaching', 'chahrazad1', 'cheftony', 'chhikara', 'christiansenn', 'cian.dafe', 'cibernatan', 'cjclaro', 'clevecross', 'cnfund', 'codymac40', 'coininstant', 'comcentrate', 'commine', 'condra', 'cousteau', 'crowfromwithin', 'cryptobiker', 'cryptoeasy', 'cryptoid870', 'cryptojoy.com', 'cryptotrends', 'cryptovpn', 'cuckoo', 'cwensor', 'dailybitcoinnews', 'dajohns1420', 'damirkatusic', 'damono', 'dave-hughes', 'davidbrogan', 'dawnlindholm', 'dcat', 'deeallen', 'demeterz01']
------------------------------------------------------------
...
Or even better: meet people who are followed by people that you follow
for following in f.following(sys.argv[1]):
print("%s follows %s" % (following, f.following(following)))
print(60*"-")
and the result gets interesting...
------------------------------------------------------------
jesta follows ['abit', 'andrarchy', 'anwenbaumeister', 'anyx', 'arhag', 'berniesanders', 'biophil', 'cass', 'clains', 'cloverme', 'complexring', 'cryptogee', 'dan', 'dantheman', 'dras', 'fabien', 'fyrstikken', 'hisnameisolllie', 'jamtaylor', 'jasonmcz', 'jeska', 'kevinwong', 'leon-fu', 'liberosist', 'lukmarcus', 'ned', 'originate', 'ozchartart', 'pharesim', 'riverhead', 'roelandp', 'smooth', 'someguy123', 'steemapp', 'steempower', 'stellabelle', 'summon', 'the-alien', 'theoretical', 'tombstone', 'tuck-fheman', 'void', 'wackou', 'xeldal', 'xeroc']
------------------------------------------------------------
xeroc follows ['arhag', 'ash', 'bacchist', 'bitcalm', 'blocktrades', 'cass', 'clains', 'clayop', 'complexring', 'cryptoctopus', 'ned', 'officialfuzzy', 'onceuponatime', 'pharesim', 'riverhead', 'stan', 'stellabelle', 'svk']
------------------------------------------------------------
I put all examples in GitHub: https://github.com/cryptomental/steem-experiments/commit/6211f20f4247c811f2ef6ff07af33826d6b06a5b
Feel free to experiment more... ;-) I will add this soon to instant-steem
You can investigate ANY STEEM account with this approach.
This is excellent!
I guess a further step could be to create a list of people who those you follow are following, and sort it by number of times they appear in the results, so you can see who are some popular people that you may want to follow. You could also find out if you are already following each of these people.
Thanks for your your work on this, and for sharing the code!
Thanks for the input, I will try to get this sorted out ! ;-)
I posted the solution here https://steemit.com/steemit/@cryptomental/how-to-find-popular-people-that-you-may-want-to-follow
thats great job :)