Using LostCircles’ Graphml files with NodeXL

LostCircles (https://lostcircles.com/) uses a proprietary format that NodeXL fails to open and use.

Below is a workaround for this problem and a step by step approach to charting your Facebook network of friends:

  1. Open the “Graphml (No Pics)” file downloaded from LostCircles
  2. Find the <node id=”n0″> tag and delete all the text that precedes it
  3. Copy and paste the text below before the  <node id=”n0″> tag:
<?xml version="1.0" encoding="UTF-8"?>
<graphml xmlns="http://graphml.graphdrawing.org/xmlns">
<key attr.name="label" attr.type="string" for="node" id="label"/>
<key attr.name="Edge Label" attr.type="string" for="edge" id="edgelabel"/>
<key attr.name="weight" attr.type="double" for="edge" id="weight"/>
<key attr.name="r" attr.type="int" for="node" id="r"/>
<key attr.name="g" attr.type="int" for="node" id="g"/>
<key attr.name="b" attr.type="int" for="node" id="b"/>
<key attr.name="x" attr.type="float" for="node" id="x"/>
<key attr.name="y" attr.type="float" for="node" id="y"/>
<key attr.name="size" attr.type="float" for="node" id="size"/>
<key attr.name="id" attr.type="string" for="node" id="d0"/>
<key attr.name="name" attr.type="string" for="node" id="d1"/>
<key attr.name="userName" attr.type="string" for="node" id="d2"/>
<key attr.name="profile" attr.type="string" for="node" id="d3"/>
<key attr.name="dataUrl" attr.type="string" for="node" id="d4"/>
<graph edgedefault="undirected">
  1. Save the file or Save it As a new GraphML file
  2. Open NodeXL and “import from GraphML file”
  3. Group by cluster and put all neighborless vertices in one group
  4. Go to the Vertices sheet
  5. The URL in the Label column is the same as the URL in the profile column (redundant information that you can replace). Change the format of the Label column from Text to General to allow the insertion of formulas (otherwise, your formulas will appear as text and will not be calculated)
  6. Delete all values in the Labels column (enter the first cell, then ctrl+space and delete)
  7. Type =[@name] in the first cell of the Labels column. It should automatically replicate to all the rows
  8. In the graph pane, choose the Harel-Koren Fast Multiscale graph style
  9. From the same dropdown, go to the Layout options and Lay out each group in its own box
  10. Draw the graph – If you have a few hundred friends on Facebook, fairly distributed in groups (family, colleagues, beer buddies, etc.), the layout should be good enough
  11. Calculate all graph metrics
  12. Autofill Columns with Vertex Size linked to Degree with vertex size options ranging from 1 (smallest) to 50 (largest)
  13. Sort the vertices by Degree
  14. Set the label position of vertices 50+ to “nowhere” to hide the least connected friends
  15. A good practice would be to set the tooltip to the username in order to see the names when you hover over a vertex

 

 

 

 

Facebooktwitter Facebooktwitter

From Smart Mobs to Smart Govs

My presentation “From Smart Mobs to Smart Govs*” in the Tech4PoliticalChange panel at the Tech4Freedom conference that took place at the Riviera Hotel in Beirut, Lebanon, on Thursday 14 and Friday 15 of December 2017.

*Smarts Govs is a term I have invented to describe governments, dictators, political establishment and political actors who learned how to use digital tools to their advantage, shifting power back to its original position.

Facebooktwitter Facebooktwitter

Facebook Cover Template with Mobile Safe Area (2017, Photoshop)

This is the new Photoshop template for Facebook page covers. It helps create compatible layouts for both Retina Display devices and mobile devices.

Usage is fairly simple. The initial display is self explanatory: the purple area is the part of the cover that will be visible on mobile. The full frame will appear on desktops.

Copy and paste your photo on a new layer or create your design – this is the version you will see on deskops :

To check the layout for mobiles, unhide the “show mobile” folder in the layers panel (make sure the “show mobile” folder is on top of all layers):

This is your mobile version:

To download the Adobe Photoshop PSD file, follow the link: Facebook Cover Template 2017

Facebooktwitter Facebooktwitter

Targeting cities or regions in Lebanon with Facebook ads

Until recently, it was impossible to target organically regions or areas in Lebanon with Facebook ads. This feature is now available. In the screenshots below, I describe the new option and the one I was using and that I still use for political marketing (voters and users can use the Internet from work or home, and vote or live in a different area).

 

The new method

In the location are of your ad creator, you are now able to select cities or regions with a radius (how many miles around the city in all direction). In the example below, I chose “no radius” to limit the targeting to Achrafieh only without its surrounding areas:

1

 

My own method

This is the method I was using before this option has been made available. It is very similar to a previous post about targeting the competition. The Idea is to find very specific pages about a region and target the fans of these pages using the “interests” option in the ad creator page. In the example below, I targeted the fans of “Achrafieh 2020” and “Achrafieh”:

2

 

This article was mentioned by Catherine Stevens in http://paper.li/cas314159?edition_id=c2714300-ff1b-11e4-871e-0cc47a0d15fd

Facebooktwitter Facebooktwitter

Targeting the competition on Facebook

Choosing the right target population for your ads is at the heart of any good marketing strategy, especially viral marketing and influence marketing strategies.

One Facebook advertising feature that very few community managers are aware of is the fact that you can target your competitors fans.

This strategy can be used either to “convert” the users of competing products or as a “free ride” strategy. The free rider problem is defined in economics as the fact to benefit from resources, goods, or services and don’t pay for them. In Internet economy, this can be using Amazon’s website to check for a product, read the reviews for it, use the comparison tool, etc., and then, buy it from a different website who doesn’t have the same evaluation tools. On Facebook, I see it as the fact to target effortlessly the fans a different brand invested time and money to collect.

Targeting the fans of a different Facebook page can be easily done using the “interests” option in the advertising targeting section of the Ad manager.

In the screenshot below, we’re targeting all Facebook users, men and women, from Lebanon, 18 years old or more, who like the Pepsi and Coca-Cola page and/or have shown interest to pages related to one or both brands. The resulting audience is 110,000 people.

1

Facebooktwitter Facebooktwitter

Banning a non-fan from a Facebook page

A Facebook troll is someone who posts aggressive comments on your page – often immediately after you publish a post –  in an attempt of creating a firestorm of controversy.

 

Most often, these trolls do not like the page and it becomes impossible to ban them or stop them using the straightforward ban user function provided by the Facebook interface.

 

Below is a method you can use to ban a non-fan:

 

1) Find the Facebook ID of the troll. To get the id, you need to use “open graph”: Type https://graph.facebook.com/username (where username is the username of the troll, e.g. https://graph.facebook.com/john.doe)

2

 

2) Open your page and go to the settings section, “banned users” function and select “people who like this” to see the whole list of users:

3

 

3) Click on F12 or Ctrl+Shift+C to inspect the page (depends on your browser. Works both with Firefox and Chrome).

In the code, locate any “remove” button and replace the ID of the user with the troll’s ID. Beware not to change the page_id (first ID in the URL)

4

 

4) Now click on the “remove” button you edited. In this example, I used ID=4. You will need to check “Ban Permanently” to prevent the user to like, write or comment in the future:

5

 

Facebooktwitter Facebooktwitter

How to count your shares

Some social plugins give you a total number of shares without specifying exactly where those shares came from.

Also, you may need to find if someone shared your link on Facebook, Twitter and other social networking websites:

Count your shares on Facebook:

– http://graph.facebook.com/?id=YourURL, e.g. http://graph.facebook.com/?id=http://nasri.messarra.com/use-two-steps-authentication-with-google-easy-steps/

Count your shares on Twitter:

– http://cdn.api.twitter.com/1/urls/count.json?url=YourURL, e.g. http://cdn.api.twitter.com/1/urls/count.json?url=http://nasri.messarra.com/use-two-steps-authentication-with-google-easy-steps/

Count your shares on Pinterest:

- http://api.pinterest.com/v1/urls/count.json?url=YourURL, e.g. http://api.pinterest.com/v1/urls/count.json?url=http://nasri.messarra.com/use-two-steps-authentication-with-google-easy-steps/

 

Facebooktwitter Facebooktwitter

Facebook Friends Social Graph Using NetVizz and NodeXL

This post is available as a PDF document.

 

  • In Facebook, search for the NetVizz application or follow this link:1

 

  • Accept the permissions required to extract data from your timeline and pages

2

  • Select “personal network”:

3

  • Click on “start”:
  • Right click on “gdf file” and save it
  • Download and Install NetVizz to NodeXL converter
  • Run NetVizz to NodeXL converter
  • Select the Import from (GDF) and Export to (GraphML) files
  • 1
  • Make sure you have the right file names and click start
  • Open a new NodeXL file
  • From the NodeXL tab, select Import, select “from GraphML file” and select the file generated by NetVizz to NodeXL converter
  • 2
  • Generate the NodeXL graph.

Match IDs with Names in the Edges Sheet

NetVizz uses Facebook IDs instead of names. In order to create two columns. Use the following formulas to add lookup columns to the table:

– =VLOOKUP([@[Vertex 1]],Vertices[[Vertex]:[Label]],8,FALSE)

– =VLOOKUP([@[Vertex 2]],Vertices[[Vertex]:[Label]],8,FALSE)

Explanation: Look for the value of vertex 1 (or 2) in the first column (always) of the table Vertices (from column Vertex to Column Label) and get the value in the 8th column. False means that Excel should look for an exact match.

lookupformula

 

 

 

Facebooktwitter Facebooktwitter