# Cyber-Physical-Social Frameworks for Urban Big Data Systems: A Survey
## 4 Data Sources
### Mobile Crowd Sensing
#### 4.2.2 User-Contributed Data from Online Social Networks  
The immediacy of messages posted on social networks means that these can act as a rich and timely source of city-specific information. With research (eMarketers.com [85]) on social network usage revealing that 2.34 billion people, equating to approximately 68% of the global population with internet access, use social networks such as Twitter [86] and Foursquare [87], they are \"being widely recognized as a complementary or corroborative information source for city events\" [20; 21]. The information mined from these networks can be combined with data obtained from sensor networks or provide a semantic context to events extracted from such physical-world data.  
The Twitter micro-blogging platform allows its users to post messages, called tweets, of up to 140 characters in length, thus constituting the textual component of social network data sources. Twittersupports both push (via a streaming API) and pull-based (via a RESTful API) methods for retrieval of tweets. The streaming API streams a sample of public tweets (estimated to be about 1% [88]). It can be filtered when requested, for example by location or containing a certain hashtag. The REST API is used for querying public user accounts or past data, with rate limit restrictions on the number of requests per hour. With its adoption in many countries (over 500 million users world-wide [20]), many research works have mined tweets as a source of reliable city information. The extracted tweets are in the following format: message text, user ID, tweet ID and published date. Popular uses of Twitter messages in urban CPSS applications have been to gather user perception of air pollution in a city [32], mine representative terms for traffic incidents [89] and to decipher trip intent [19]. As pointed out in [21], the restrictive message length of tweets and the informal nature of social networking means that messages do not follow grammar syntax, contain misspelled or noisy words and also lack context.  
The Foursquare social network comprises of users 'checking-in' to a venue, with the list of available venues dependent on the user's location. The user location is determined either by using the mobile phone's GPS sensors or specified by the application. Recently, (as of mid-2014), the social elements of the Foursquare network, which include the checking-in feature as well as the possibility of sharing it with friends, has been moved to an app called Swarm. The data available through the specified API includes the time, type, user details and venue details (name, location, category, etc.). The modality and format of the available data (primarily numeric) enables its direct manipulation through statistical methods as well as integration with numerical time-series data obtained from physical sensors.  
The available access methods feature a REST API with restrictions on the number of requests per hour, dependent on the type of the request. Moreover, developers are not able to search for public check-ins, but can gain access to public check-ins if they know the corresponding check-in ID. Other data access methods include a User Push API and Venue Push API, which involves notifications to an application when a check-in occurs. However, data through this method is only made available to venue owners or authorized users. Surveyed works using Foursquare check-in data include [57], where data from the FourSquare API was sampled every 30 min, with venue locations arranged in a grid of \"listening posts\". The obtained data included the time of the query, the current check-ins and total check-ins from which the authors derived the difference in users checking in since the last recorded check in.