{"$schema":"https://vega.github.io/schema/vega-lite/v5.json","config":{"axis":{"ticks":false,"domain":false,"labelAngle":45,"labelLimit":0},"view":{"stroke":null}},"concat":[{"encoding":{"theta":{"field":"Observation","type":"quantitative"},"color":{"field":"Ethnic group (8 categories)","legend":null},"tooltip":[{"field":"Ethnic group (8 categories)","title":"Ethnic group"},{"field":"totE","title":"Total Amount"}]},"transform":[{"joinaggregate":[{"op":"sum","field":"Observation","as":"totE"}],"groupby":["Ethnic group (8 categories)"]},{"filter":"datum['Ethnic group (8 categories)'] != 'Other ethnic group'"},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totA"}],"groupby":["Age (C) (3 categories)"]},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totS"}],"groupby":["Sex (2 categories)"]}],"mark":{"type":"arc","innerRadius":50},"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/London.csv"}},{"encoding":{"theta":{"field":"Observation","type":"quantitative"},"color":{"field":"Age (C) (3 categories)"},"tooltip":[{"field":"Age (C) (3 categories)","title":"Age Group"},{"field":"totA","title":"Total amount"}]},"transform":[{"joinaggregate":[{"op":"sum","field":"Observation","as":"totE"}],"groupby":["Ethnic group (8 categories)"]},{"filter":"datum['Ethnic group (8 categories)'] != 'Other ethnic group'"},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totA"}],"groupby":["Age (C) (3 categories)"]},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totS"}],"groupby":["Sex (2 categories)"]}],"mark":{"type":"arc","innerRadius":50},"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/London.csv"}},{"encoding":{"theta":{"field":"Observation","type":"quantitative"},"color":{"field":"Sex (2 categories)"},"tooltip":[{"field":"Sex (2 categories)","title":"Gender"},{"field":"totS","title":"Total amount"}]},"transform":[{"joinaggregate":[{"op":"sum","field":"Observation","as":"totE"}],"groupby":["Ethnic group (8 categories)"]},{"filter":"datum['Ethnic group (8 categories)'] != 'Other ethnic group'"},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totA"}],"groupby":["Age (C) (3 categories)"]},{"joinaggregate":[{"op":"sum","field":"Observation","as":"totS"}],"groupby":["Sex (2 categories)"]}],"mark":{"type":"arc","innerRadius":50},"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/London.csv"}}]}
{"$schema":"https://vega.github.io/schema/vega-lite/v5.json","width":600,"height":370.82818294190355,"config":{"axis":{"ticks":false,"domain":false,"labelAngle":45,"labelLimit":0,"grid":false},"view":{"stroke":null}},"transform":[{"filter":"datum['Self-defined ethnicity'] != 'Other ethnic group - Not stated' && datum['Self-defined ethnicity'] != 'Other ethnic group - Any other ethnic group' && datum['Self-defined ethnicity'] != '' && datum.Gender != ''&& datum.Gender != 'Other' && datum['Age range'] != null"},{"filter":{"param":"Age range"}},{"joinaggregate":[{"op":"count","field":"Outcome","as":"tot"}],"groupby":["Self-defined ethnicity"]}],"encoding":{"x":{"field":"Self-defined ethnicity","axis":{"labelPadding":0,"ticks":false}},"xOffset":{"field":"Gender"},"y":{"aggregate":"count","axis":{"title":"Total stop and search","values":[1000,2000,3000]}},"color":{"field":"Outcome"},"tooltip":[{"field":"tot","title":"Total stops"},{"field":"Outcome"},{"aggregate":"count"},{"field":"Self-defined ethnicity"}]},"mark":"bar","data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/2023-02-metropolitan-stop-and-search.csv"},"params":[{"name":"Age range","bind":{"input":"select","name":"Age range","options":["18-24","25-34","over 34"]},"select":{"type":"point","fields":["Age range"]}}]}
{"$schema":"https://vega.github.io/schema/vega-lite/v5.json","width":680,"height":450,"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/street.csv"},"transform":[{"filter":{"param":"selection"}},{"joinaggregate":[{"op":"count","field":"Crime ID","as":"Count of Crime ID"}],"groupby":["LSOA code"]},{"lookup":"LSOA code","from":{"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/topo_E09000026.json","format":{"type":"topojson","feature":"E09000026"}},"key":"properties.LSOA11CD"},"as":"geo"}],"projection":{"type":"mercator","rotate":{"expr":"[2,0,0]"}},"encoding":{"shape":{"field":"geo","type":"geojson"},"color":{"field":"Count of Crime ID","type":"quantitative","scale":{"scheme":"lightmulti"},"title":"Crimes Per LSOA"},"tooltip":[{"field":"LSOA name"},{"field":"Count of Crime ID"}]},"params":[{"name":"selection","bind":{"input":"select","name":"Crime type","options":["Burglary","Drugs","Criminal damage and arson","Other theft","Robbery","Public order","Vehicle crime","Violence and sexual offences","Shoplifting","Bicycle theft","Possession of weapons","Theft from the person","Other crime"]},"select":{"type":"point","fields":["Crime type"]}}],"mark":{"type":"geoshape","stroke":"white"}}
{"$schema":"https://vega.github.io/schema/vega-lite/v5.json","config":{"view":{"stroke":null}},"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/street.csv"},"transform":[{"lookup":"Crime ID","from":{"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/2023-02-metropolitan-outcomes.csv"},"key":"Crime ID","fields":["Outcome type"]}},{"filter":"datum['Last outcome category'] != 'Under investigation' && datum['Last outcome category'] != 'Investigation complete; no suspect identified' && datum['Last outcome category'] != 'Awaiting court outcome'&& datum['Crime type'] != null&& datum['Crime type'] != 'Bicycle theft'&& datum['Outcome type'] != null"}],"encoding":{"theta":{"aggregate":"count","type":"quantitative"},"color":{"field":"Crime type"},"tooltip":[{"field":"Crime type"},{"aggregate":"count","title":"Amount"}]},"mark":{"type":"arc","innerRadius":50}}
{"$schema":"https://vega.github.io/schema/vega-lite/v5.json","height":400,"width":400,"transform":[{"lookup":"Crime ID","from":{"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/street.csv"},"key":"Crime ID","fields":["Crime type"]}},{"filter":"datum['Last outcome category'] != 'Under investigation' && datum['Last outcome category'] != 'Investigation complete; no suspect identified' && datum['Last outcome category'] != 'Awaiting court outcome'&& datum['Crime type'] != null&& datum['Crime type'] != 'Bicycle theft'"}],"data":{"url":"https://raw.githubusercontent.com/Mohyidian/test/main/2023-02-metropolitan-outcomes.csv"},"encoding":{"x":{"field":"Outcome type","type":"nominal","title":"","axis":{"labelPadding":3,"ticks":false}},"y":{"field":"Crime type","axis":{"labelPadding":3,"ticks":false}},"color":{"aggregate":"count","type":"quantitative","scale":{"scheme":"lightmulti"},"title":"Crimes Per LSOA"},"tooltip":[{"aggregate":"count"}]},"mark":{"type":"circle","size":400}}