SlideShare a Scribd company logo
1 of 11
Download to read offline
San Francisco Crime Analysis – Report
-By Rohit Dandona and Sameer Darekar
Introduction:
From 1934 to 1963, San Francisco was infamous for housing some of the world's most notorious
criminals on the inescapable island of Alcatraz. Today, the city is known more for its tech scene than its
criminal past. But, with rising wealth inequality, housing shortages, and a proliferation of expensive
digital toys riding BART to work, there is no scarcity of crime in the city by the bay. This project examines
the San Francisco Police Department crime records between January 1st 2003 and May 13st 2015. It
visualizes the trends of major crimes and drugs in the city across time and locations. This analysis has
been carried out to facilitate law enforcement officers to enhance their strategies based on time and
location.
R and Tableau have been used for data processing and visualizations.
Dataset:
This dataset contains incidents derived from SFPD Crime Incident Reporting system. The data ranges
from 1/1/2003 to 5/13/2015.
Data fields:
 Dates - timestamp of the crime incident
 Category - category of the crime incident
 Descript - detailed description of the crime incident
 DayOfWeek - the day of the week
 PdDistrict - name of the Police Department District
 Resolution - how the crime incident was resolved
 Address - the approximate street address of the crime incident
 X – Longitude
 Y - Latitude
Data-Preprocessing:
The date field in the dataset is a timestamp present in the “MM/dd/yyyy hh:mm:ss” format and is not of
much utility if used as such.
Tableau provides the facility of parsing through a timestamp through a utility called “DATEPART ” and
extract specific segments of the timestamp. For example:
DATEPART('hour',[Dates])
A part of the analysis required representing the data by five separate parts of the day. The following
construct was used to derive a column in Tableau:
IF DAY([Dates]) >= 4 AND DAY([Dates]) <= 8 THEN 'EARLY MORNING(4 AM to 8 AM)'
ELSEIF DAY([Dates]) > 8 AND DAY([Dates]) < 12 THEN 'MORNING(8 AM to 12 PM)'
ELSEIF DAY([Dates]) >= 12 AND DAY([Dates]) < 17 THEN 'AFTERNOON(12 PM to 5 PM)'
ELSEIF DAY([Dates]) >= 17 AND DAY([Dates]) <= 21 THEN 'EVENING (5 PM to 9 PM)'
ELSE 'NIGHT(9 PM to 4 AM)' END
The address data is of the following form
1. 1500 Block of LOMBARD ST
2. OAK ST / LAGUNA ST
The first one is actually a location on the street but the second one is the intersection of two streets, we
extracted the streets from both of them for plotting the bubble chart shown in analysis section. The rest
of the columns are clean and no further processing was required.
Analysis of Crime
 Trends:
There are 39 categories of crime report incidents available in the dataset including “Other offenses”
and “Non-criminal”.
Larceny and theft was the most common crime in San Francisco between January 1st 2003 and May
13th 2015, with a total of 174,900 reported incidents. The next two highest crime categories, “Other
offenses” (98,281 reported incidents) and “Non-criminal” (98,172 reported incidents), are omitted
from discussion in the analyses. Instead, the key focus is on the following high crime categories:
larceny and theft, assault (76,876 reported incidents), drugs (53,971 reported incidents), vehicle
theft (53,781 reported incidents), vandalism (44,725 reported incidents), drugs (21,910 reported
incidents) and burglary (19,226 reported incidents).
 Month wise distribution:
Since the crime incidents recorded in 2015 are only till May, those records have been removed
for this analysis. The month of February is the safest and is observed to have the least crime
incidents reported. October is the least safe with the maximum number of reported crime
incidents.
 Region wise distribution:
A contour plot to represent the region wise density of crime leveraging the available
latitude/longitude information of the reported crime, is as follows:
A giant hotspot can be observed in the Southern and Tenderloin region with relatively less
dense plots in the surrounding neighborhoods. Majority of the crime seems to be concentrated
in these and surrounding regions.
Plotting a line graph to represent crime in each region on each day of a week uncovers some
interesting trends:
Crime rate by day of the week:
Clearly, the Southern region is the most notorious with the maximum number of crimes
reported followed by the Northern region. Richmond is the safest place to be in San Francisco.
The rate of crime is observed to increase over the weekend. The number of reported incidents
seems to be the maximum on Fridays with a total number of 133,743 reported incidents. For
almost all regions, the same trend can be observed. Tenderloin, however, is an exception as the
crime rate in this region decreases over the weekend and is the highest on Wednesdays.
Wednesday, Friday and Saturday are the most crime prominent days. Interestingly, the least
amount of incidents were reported on Mondays (116,707 reported incidents) followed by
Sundays. In the Southern, Northern, Central and Mission districts, the number of crimes
increased sharply on Friday and Saturday, then declined for rest of the week.
 Specific crime trends
We examine the crime trends of a hand full of crimes (Kidnapping, Fraud, Robbery, Missing
Person, Burglary, Vandalism, Vehicle Theft, Drug/Narcotics, Assault and Larceny/Theft). The
following trends are observed:
Interestingly, Drug/Narcotic related crimes decrease over the weekend (unlike other
categories). The related reported incidents are the maximum on a Friday.
Among the high crime categories, larceny and theft tend to occur on Friday and Saturday. On
the other hand, the occurrences of assault steadily increased from Thursday to Sunday, while
burglary generally occurred more often during the weekdays than the weekends. Drug crimes
were most commonly reported on Wednesday and least reported during the weekends, and
robberies happened by approximately the same frequency every day.
 Hourly Crime Analysis
The overall hourly crime trends are as follows:
Hourly trend analysis for specific crimes:
The hourly trends unravel some interesting crime facts:
 5 am is the safest part of a day with 8,637 reported incidents and 6 pm is the most
dangerous hour with 55,104 reported incidents.
 Surprisingly, 12 pm is the second most dangerous hour during a day and in fact is the
hour where incidents reported under some crime categories is maximum.
 Kidnapping and stolen property incidents take place uniformly throughout the day
Violent Crimes in San Francisco: Assault, Robbery and Sex Offences (forcible)
Distribution:
Violent crime density (each) by parts of day:
 Assault:
Part of Day
Time
Frame
Early
Morning
4am to
8am
Morning
8am to
12pm
Afternoon
12pm to
5 pm
Evening
5pm to
9pm
Night
9pm to
4am
Distribution of Assault crimes is more or less the same at different times of the day.
 Robbery:
A slight shift in epicenter of the crime can be observed over different parts of the day.
 Sex Offences(forcible):
Different Patterns can be observed at different time with increase in density at night.
 Larceny and Theft:
Crime is spread across multiple regions early in the mornings and at night. It is concentrated on
a single region in the afternoon.
Food for thought
 The following shows a bar graph representing the percentage of incidents which have been
investigated by law enforcement agencies vs the ones that haven’t been.
Surprisingly, for 61.02% of the reported incidents no conclusive action has been taken.
 The following graph shows the top three streets where the maximum crime incidents were
reported [Bryant Street, Market Street, Mission Street]:
The police commission office is located on 850 Bryant Street which is just near the 800 Bryant
Street which has the most crime rate in terms of streets.
Market Street, with the second highest number of crime incidents reported, has a police station
0.5 miles away from it:
Conclusion
 Tenderloin and Southern are the PD districts needing special attention
 Famous Neighborhoods have more crime rate
 Violent crime seems to be concentrated around Tenderloin.
 Assault is most common violent crime.
 Crime rate is highest at 6 pm and lowest at 5 am with a spike at 12 in afternoon that means
whenever there are people on the streets the crime rate is higher.
 Pattern observed for each crime should be followed while deploying police personnel
 SFPD needs to work more proactively as the 61% of cases are still not resolved
 Also the crime rate near the police station needs to be decreased the SFPD needs to create
terror in the minds of criminals.
 Need to find out why the months February has the lowest and October has the highest crime
commited
 The second part of the Kaggle competetion that is predicting the classes of the crime has also
been completed and in process for further improvement, the current rank is 672 out of
1886[4].
References
[1] https://www.kaggle.com/c/sf-crime/data for Dataset
[2] http://www.r-bloggers.com/google-maps-and-ggmap/ for google maps and using ggmap in
R.
[3] http://blog.dominodatalab.com/geographic-visualization-with-rs-ggmaps/ creating clusters
and heatmaps in R
[4] https://www.kaggle.com/c/sf-crime/leaderboard?submissionId=2963937 Kaggle competition
submission

More Related Content

Viewers also liked

San Francisco Crime Prediction Report
San Francisco Crime Prediction ReportSan Francisco Crime Prediction Report
San Francisco Crime Prediction ReportRohit Dandona
 
San Francisco Crime Infographics
San Francisco Crime InfographicsSan Francisco Crime Infographics
San Francisco Crime InfographicsRohit Dandona
 
San Francisco Crime Analysis Classification Kaggle contest
San Francisco Crime Analysis Classification Kaggle contestSan Francisco Crime Analysis Classification Kaggle contest
San Francisco Crime Analysis Classification Kaggle contestSameer Darekar
 
San Francisco Crime Analysis
San Francisco Crime AnalysisSan Francisco Crime Analysis
San Francisco Crime AnalysisRohit Dandona
 
Story Tellers: Hartford Crime Analysis
Story Tellers: Hartford Crime AnalysisStory Tellers: Hartford Crime Analysis
Story Tellers: Hartford Crime AnalysisNeil Ryan
 
2014 Chicago Crime Data Analysis
2014 Chicago Crime Data Analysis 2014 Chicago Crime Data Analysis
2014 Chicago Crime Data Analysis Yawen Li
 
Crime Analysis & Prediction System
Crime Analysis & Prediction SystemCrime Analysis & Prediction System
Crime Analysis & Prediction SystemBigDataCloud
 

Viewers also liked (8)

San Francisco Crime Prediction Report
San Francisco Crime Prediction ReportSan Francisco Crime Prediction Report
San Francisco Crime Prediction Report
 
San Francisco Crime Infographics
San Francisco Crime InfographicsSan Francisco Crime Infographics
San Francisco Crime Infographics
 
San Francisco Crime Analysis Classification Kaggle contest
San Francisco Crime Analysis Classification Kaggle contestSan Francisco Crime Analysis Classification Kaggle contest
San Francisco Crime Analysis Classification Kaggle contest
 
San Francisco Crime Analysis
San Francisco Crime AnalysisSan Francisco Crime Analysis
San Francisco Crime Analysis
 
Story Tellers: Hartford Crime Analysis
Story Tellers: Hartford Crime AnalysisStory Tellers: Hartford Crime Analysis
Story Tellers: Hartford Crime Analysis
 
2014 Chicago Crime Data Analysis
2014 Chicago Crime Data Analysis 2014 Chicago Crime Data Analysis
2014 Chicago Crime Data Analysis
 
Crime Analysis
Crime AnalysisCrime Analysis
Crime Analysis
 
Crime Analysis & Prediction System
Crime Analysis & Prediction SystemCrime Analysis & Prediction System
Crime Analysis & Prediction System
 

Similar to San Francisco crime analysis

Units 4, 5, 24, 31 task 4 secondary evidence (3)
Units 4, 5, 24, 31   task 4 secondary evidence (3)Units 4, 5, 24, 31   task 4 secondary evidence (3)
Units 4, 5, 24, 31 task 4 secondary evidence (3)bentheman21
 
Units 4, 5, 24, 31 task 4 secondary evidence
Units 4, 5, 24, 31   task 4 secondary evidenceUnits 4, 5, 24, 31   task 4 secondary evidence
Units 4, 5, 24, 31 task 4 secondary evidencelrosenfeld1
 
Secondary evidence task 4
Secondary evidence task 4Secondary evidence task 4
Secondary evidence task 4nikonmedia
 
Secondary evidence
Secondary evidenceSecondary evidence
Secondary evidencekarrass1
 
Police Minister Bheki Cele's speaking notes on the Crime Statistics
Police Minister Bheki Cele's speaking notes on the Crime StatisticsPolice Minister Bheki Cele's speaking notes on the Crime Statistics
Police Minister Bheki Cele's speaking notes on the Crime StatisticsSABC News
 
Units 4, 5, 24, 31 task 4 secondary evidence (1)
Units 4, 5, 24, 31   task 4 secondary evidence (1)Units 4, 5, 24, 31   task 4 secondary evidence (1)
Units 4, 5, 24, 31 task 4 secondary evidence (1)lrosenfeld1
 
San Francisco Crime Classification with Tableau 10.4
San Francisco Crime Classification with Tableau 10.4San Francisco Crime Classification with Tableau 10.4
San Francisco Crime Classification with Tableau 10.4RAHUL SINGH
 
Crimes Project - Data Mining & Analytics
Crimes Project - Data Mining & AnalyticsCrimes Project - Data Mining & Analytics
Crimes Project - Data Mining & AnalyticsTeri Grossheim
 
M.Gallagher Exam2
M.Gallagher Exam2M.Gallagher Exam2
M.Gallagher Exam2mgalla22
 
FBI report compared to crimes in Sweden
FBI report compared to crimes in SwedenFBI report compared to crimes in Sweden
FBI report compared to crimes in SwedenADVICEDERNBACK
 
Student #1 I have chosen to write about the history of data anal.docx
Student #1 I have chosen to write about the history of data anal.docxStudent #1 I have chosen to write about the history of data anal.docx
Student #1 I have chosen to write about the history of data anal.docxjohniemcm5zt
 
Crime Analysis at Chicago
Crime Analysis at ChicagoCrime Analysis at Chicago
Crime Analysis at ChicagoRoshik Ganesan
 
An Intelligence Analysis of Crime Data for Law Enforcement Using Data Mining
An Intelligence Analysis of Crime Data for Law Enforcement Using Data MiningAn Intelligence Analysis of Crime Data for Law Enforcement Using Data Mining
An Intelligence Analysis of Crime Data for Law Enforcement Using Data MiningWaqas Tariq
 
Analyzing the Spatial Distribution of Crime in Annapolis County
Analyzing the Spatial Distribution of Crime in Annapolis CountyAnalyzing the Spatial Distribution of Crime in Annapolis County
Analyzing the Spatial Distribution of Crime in Annapolis CountyCOGS Presentations
 
Building an urban theft map by analyzing newspaper - SMAP 2018
Building an urban theft map by analyzing newspaper - SMAP 2018Building an urban theft map by analyzing newspaper - SMAP 2018
Building an urban theft map by analyzing newspaper - SMAP 2018Laura Po
 
georgia-tech-atlanta
georgia-tech-atlantageorgia-tech-atlanta
georgia-tech-atlantaPeter Kim
 
Untold story of karachi
Untold story of karachiUntold story of karachi
Untold story of karachiRobin Patras
 
Stategic_Crime_Report_Crime_Analyses_340[1]
Stategic_Crime_Report_Crime_Analyses_340[1]Stategic_Crime_Report_Crime_Analyses_340[1]
Stategic_Crime_Report_Crime_Analyses_340[1]Erasmo Skylar Ruiz
 
Be Prepared: Get the Real Facts on Crime
Be Prepared: Get the Real Facts on CrimeBe Prepared: Get the Real Facts on Crime
Be Prepared: Get the Real Facts on CrimeChristian Watson
 

Similar to San Francisco crime analysis (20)

Units 4, 5, 24, 31 task 4 secondary evidence (3)
Units 4, 5, 24, 31   task 4 secondary evidence (3)Units 4, 5, 24, 31   task 4 secondary evidence (3)
Units 4, 5, 24, 31 task 4 secondary evidence (3)
 
Units 4, 5, 24, 31 task 4 secondary evidence
Units 4, 5, 24, 31   task 4 secondary evidenceUnits 4, 5, 24, 31   task 4 secondary evidence
Units 4, 5, 24, 31 task 4 secondary evidence
 
Secondary evidence task 4
Secondary evidence task 4Secondary evidence task 4
Secondary evidence task 4
 
Secondary evidence
Secondary evidenceSecondary evidence
Secondary evidence
 
Police Minister Bheki Cele's speaking notes on the Crime Statistics
Police Minister Bheki Cele's speaking notes on the Crime StatisticsPolice Minister Bheki Cele's speaking notes on the Crime Statistics
Police Minister Bheki Cele's speaking notes on the Crime Statistics
 
Units 4, 5, 24, 31 task 4 secondary evidence (1)
Units 4, 5, 24, 31   task 4 secondary evidence (1)Units 4, 5, 24, 31   task 4 secondary evidence (1)
Units 4, 5, 24, 31 task 4 secondary evidence (1)
 
Secondary Evidence
Secondary EvidenceSecondary Evidence
Secondary Evidence
 
San Francisco Crime Classification with Tableau 10.4
San Francisco Crime Classification with Tableau 10.4San Francisco Crime Classification with Tableau 10.4
San Francisco Crime Classification with Tableau 10.4
 
Crimes Project - Data Mining & Analytics
Crimes Project - Data Mining & AnalyticsCrimes Project - Data Mining & Analytics
Crimes Project - Data Mining & Analytics
 
M.Gallagher Exam2
M.Gallagher Exam2M.Gallagher Exam2
M.Gallagher Exam2
 
FBI report compared to crimes in Sweden
FBI report compared to crimes in SwedenFBI report compared to crimes in Sweden
FBI report compared to crimes in Sweden
 
Student #1 I have chosen to write about the history of data anal.docx
Student #1 I have chosen to write about the history of data anal.docxStudent #1 I have chosen to write about the history of data anal.docx
Student #1 I have chosen to write about the history of data anal.docx
 
Crime Analysis at Chicago
Crime Analysis at ChicagoCrime Analysis at Chicago
Crime Analysis at Chicago
 
An Intelligence Analysis of Crime Data for Law Enforcement Using Data Mining
An Intelligence Analysis of Crime Data for Law Enforcement Using Data MiningAn Intelligence Analysis of Crime Data for Law Enforcement Using Data Mining
An Intelligence Analysis of Crime Data for Law Enforcement Using Data Mining
 
Analyzing the Spatial Distribution of Crime in Annapolis County
Analyzing the Spatial Distribution of Crime in Annapolis CountyAnalyzing the Spatial Distribution of Crime in Annapolis County
Analyzing the Spatial Distribution of Crime in Annapolis County
 
Building an urban theft map by analyzing newspaper - SMAP 2018
Building an urban theft map by analyzing newspaper - SMAP 2018Building an urban theft map by analyzing newspaper - SMAP 2018
Building an urban theft map by analyzing newspaper - SMAP 2018
 
georgia-tech-atlanta
georgia-tech-atlantageorgia-tech-atlanta
georgia-tech-atlanta
 
Untold story of karachi
Untold story of karachiUntold story of karachi
Untold story of karachi
 
Stategic_Crime_Report_Crime_Analyses_340[1]
Stategic_Crime_Report_Crime_Analyses_340[1]Stategic_Crime_Report_Crime_Analyses_340[1]
Stategic_Crime_Report_Crime_Analyses_340[1]
 
Be Prepared: Get the Real Facts on Crime
Be Prepared: Get the Real Facts on CrimeBe Prepared: Get the Real Facts on Crime
Be Prepared: Get the Real Facts on Crime
 

Recently uploaded

专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改
专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改
专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改yuu sss
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubaihf8803863
 
INTERNSHIP ON PURBASHA COMPOSITE TEX LTD
INTERNSHIP ON PURBASHA COMPOSITE TEX LTDINTERNSHIP ON PURBASHA COMPOSITE TEX LTD
INTERNSHIP ON PURBASHA COMPOSITE TEX LTDRafezzaman
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Sapana Sha
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home ServiceSapana Sha
 
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理科罗拉多大学波尔得分校毕业证学位证成绩单-可办理
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理e4aez8ss
 
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024thyngster
 
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...ThinkInnovation
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)jennyeacort
 
Call Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceCall Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceSapana Sha
 
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.ppt
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.pptdokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.ppt
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.pptSonatrach
 
Beautiful Sapna Vip Call Girls Hauz Khas 9711199012 Call /Whatsapps
Beautiful Sapna Vip  Call Girls Hauz Khas 9711199012 Call /WhatsappsBeautiful Sapna Vip  Call Girls Hauz Khas 9711199012 Call /Whatsapps
Beautiful Sapna Vip Call Girls Hauz Khas 9711199012 Call /Whatsappssapnasaifi408
 
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一F sss
 
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAmazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAbdelrhman abooda
 
RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998YohFuh
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...soniya singh
 
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookvip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookmanojkuma9823
 
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort servicejennyeacort
 

Recently uploaded (20)

专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改
专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改
专业一比一美国俄亥俄大学毕业证成绩单pdf电子版制作修改
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
 
INTERNSHIP ON PURBASHA COMPOSITE TEX LTD
INTERNSHIP ON PURBASHA COMPOSITE TEX LTDINTERNSHIP ON PURBASHA COMPOSITE TEX LTD
INTERNSHIP ON PURBASHA COMPOSITE TEX LTD
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service
 
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理科罗拉多大学波尔得分校毕业证学位证成绩单-可办理
科罗拉多大学波尔得分校毕业证学位证成绩单-可办理
 
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
 
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...
Predictive Analysis - Using Insight-informed Data to Determine Factors Drivin...
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
 
Call Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceCall Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts Service
 
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.ppt
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.pptdokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.ppt
dokumen.tips_chapter-4-transient-heat-conduction-mehmet-kanoglu.ppt
 
Beautiful Sapna Vip Call Girls Hauz Khas 9711199012 Call /Whatsapps
Beautiful Sapna Vip  Call Girls Hauz Khas 9711199012 Call /WhatsappsBeautiful Sapna Vip  Call Girls Hauz Khas 9711199012 Call /Whatsapps
Beautiful Sapna Vip Call Girls Hauz Khas 9711199012 Call /Whatsapps
 
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
 
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAmazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
 
RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
 
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookvip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
 
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
 

San Francisco crime analysis

  • 1. San Francisco Crime Analysis – Report -By Rohit Dandona and Sameer Darekar Introduction: From 1934 to 1963, San Francisco was infamous for housing some of the world's most notorious criminals on the inescapable island of Alcatraz. Today, the city is known more for its tech scene than its criminal past. But, with rising wealth inequality, housing shortages, and a proliferation of expensive digital toys riding BART to work, there is no scarcity of crime in the city by the bay. This project examines the San Francisco Police Department crime records between January 1st 2003 and May 13st 2015. It visualizes the trends of major crimes and drugs in the city across time and locations. This analysis has been carried out to facilitate law enforcement officers to enhance their strategies based on time and location. R and Tableau have been used for data processing and visualizations. Dataset: This dataset contains incidents derived from SFPD Crime Incident Reporting system. The data ranges from 1/1/2003 to 5/13/2015. Data fields:  Dates - timestamp of the crime incident  Category - category of the crime incident  Descript - detailed description of the crime incident  DayOfWeek - the day of the week  PdDistrict - name of the Police Department District  Resolution - how the crime incident was resolved  Address - the approximate street address of the crime incident  X – Longitude  Y - Latitude Data-Preprocessing: The date field in the dataset is a timestamp present in the “MM/dd/yyyy hh:mm:ss” format and is not of much utility if used as such. Tableau provides the facility of parsing through a timestamp through a utility called “DATEPART ” and extract specific segments of the timestamp. For example: DATEPART('hour',[Dates])
  • 2. A part of the analysis required representing the data by five separate parts of the day. The following construct was used to derive a column in Tableau: IF DAY([Dates]) >= 4 AND DAY([Dates]) <= 8 THEN 'EARLY MORNING(4 AM to 8 AM)' ELSEIF DAY([Dates]) > 8 AND DAY([Dates]) < 12 THEN 'MORNING(8 AM to 12 PM)' ELSEIF DAY([Dates]) >= 12 AND DAY([Dates]) < 17 THEN 'AFTERNOON(12 PM to 5 PM)' ELSEIF DAY([Dates]) >= 17 AND DAY([Dates]) <= 21 THEN 'EVENING (5 PM to 9 PM)' ELSE 'NIGHT(9 PM to 4 AM)' END The address data is of the following form 1. 1500 Block of LOMBARD ST 2. OAK ST / LAGUNA ST The first one is actually a location on the street but the second one is the intersection of two streets, we extracted the streets from both of them for plotting the bubble chart shown in analysis section. The rest of the columns are clean and no further processing was required. Analysis of Crime  Trends: There are 39 categories of crime report incidents available in the dataset including “Other offenses” and “Non-criminal”. Larceny and theft was the most common crime in San Francisco between January 1st 2003 and May 13th 2015, with a total of 174,900 reported incidents. The next two highest crime categories, “Other offenses” (98,281 reported incidents) and “Non-criminal” (98,172 reported incidents), are omitted from discussion in the analyses. Instead, the key focus is on the following high crime categories: larceny and theft, assault (76,876 reported incidents), drugs (53,971 reported incidents), vehicle theft (53,781 reported incidents), vandalism (44,725 reported incidents), drugs (21,910 reported incidents) and burglary (19,226 reported incidents).
  • 3.  Month wise distribution: Since the crime incidents recorded in 2015 are only till May, those records have been removed for this analysis. The month of February is the safest and is observed to have the least crime incidents reported. October is the least safe with the maximum number of reported crime incidents.  Region wise distribution: A contour plot to represent the region wise density of crime leveraging the available latitude/longitude information of the reported crime, is as follows:
  • 4. A giant hotspot can be observed in the Southern and Tenderloin region with relatively less dense plots in the surrounding neighborhoods. Majority of the crime seems to be concentrated in these and surrounding regions. Plotting a line graph to represent crime in each region on each day of a week uncovers some interesting trends: Crime rate by day of the week:
  • 5. Clearly, the Southern region is the most notorious with the maximum number of crimes reported followed by the Northern region. Richmond is the safest place to be in San Francisco. The rate of crime is observed to increase over the weekend. The number of reported incidents seems to be the maximum on Fridays with a total number of 133,743 reported incidents. For almost all regions, the same trend can be observed. Tenderloin, however, is an exception as the crime rate in this region decreases over the weekend and is the highest on Wednesdays. Wednesday, Friday and Saturday are the most crime prominent days. Interestingly, the least amount of incidents were reported on Mondays (116,707 reported incidents) followed by Sundays. In the Southern, Northern, Central and Mission districts, the number of crimes increased sharply on Friday and Saturday, then declined for rest of the week.  Specific crime trends We examine the crime trends of a hand full of crimes (Kidnapping, Fraud, Robbery, Missing Person, Burglary, Vandalism, Vehicle Theft, Drug/Narcotics, Assault and Larceny/Theft). The following trends are observed: Interestingly, Drug/Narcotic related crimes decrease over the weekend (unlike other categories). The related reported incidents are the maximum on a Friday. Among the high crime categories, larceny and theft tend to occur on Friday and Saturday. On the other hand, the occurrences of assault steadily increased from Thursday to Sunday, while burglary generally occurred more often during the weekdays than the weekends. Drug crimes
  • 6. were most commonly reported on Wednesday and least reported during the weekends, and robberies happened by approximately the same frequency every day.  Hourly Crime Analysis The overall hourly crime trends are as follows: Hourly trend analysis for specific crimes:
  • 7. The hourly trends unravel some interesting crime facts:  5 am is the safest part of a day with 8,637 reported incidents and 6 pm is the most dangerous hour with 55,104 reported incidents.  Surprisingly, 12 pm is the second most dangerous hour during a day and in fact is the hour where incidents reported under some crime categories is maximum.  Kidnapping and stolen property incidents take place uniformly throughout the day Violent Crimes in San Francisco: Assault, Robbery and Sex Offences (forcible) Distribution: Violent crime density (each) by parts of day:  Assault: Part of Day Time Frame Early Morning 4am to 8am Morning 8am to 12pm Afternoon 12pm to 5 pm Evening 5pm to 9pm Night 9pm to 4am
  • 8. Distribution of Assault crimes is more or less the same at different times of the day.  Robbery: A slight shift in epicenter of the crime can be observed over different parts of the day.  Sex Offences(forcible): Different Patterns can be observed at different time with increase in density at night.
  • 9.  Larceny and Theft: Crime is spread across multiple regions early in the mornings and at night. It is concentrated on a single region in the afternoon. Food for thought  The following shows a bar graph representing the percentage of incidents which have been investigated by law enforcement agencies vs the ones that haven’t been. Surprisingly, for 61.02% of the reported incidents no conclusive action has been taken.
  • 10.  The following graph shows the top three streets where the maximum crime incidents were reported [Bryant Street, Market Street, Mission Street]: The police commission office is located on 850 Bryant Street which is just near the 800 Bryant Street which has the most crime rate in terms of streets. Market Street, with the second highest number of crime incidents reported, has a police station 0.5 miles away from it:
  • 11. Conclusion  Tenderloin and Southern are the PD districts needing special attention  Famous Neighborhoods have more crime rate  Violent crime seems to be concentrated around Tenderloin.  Assault is most common violent crime.  Crime rate is highest at 6 pm and lowest at 5 am with a spike at 12 in afternoon that means whenever there are people on the streets the crime rate is higher.  Pattern observed for each crime should be followed while deploying police personnel  SFPD needs to work more proactively as the 61% of cases are still not resolved  Also the crime rate near the police station needs to be decreased the SFPD needs to create terror in the minds of criminals.  Need to find out why the months February has the lowest and October has the highest crime commited  The second part of the Kaggle competetion that is predicting the classes of the crime has also been completed and in process for further improvement, the current rank is 672 out of 1886[4]. References [1] https://www.kaggle.com/c/sf-crime/data for Dataset [2] http://www.r-bloggers.com/google-maps-and-ggmap/ for google maps and using ggmap in R. [3] http://blog.dominodatalab.com/geographic-visualization-with-rs-ggmaps/ creating clusters and heatmaps in R [4] https://www.kaggle.com/c/sf-crime/leaderboard?submissionId=2963937 Kaggle competition submission