Publications by David Leydet

Topic Modeling

03.10.2024

Introduction The following is example code and discussion from Schweinberger, Martin. 2024. Topic Modeling with R. Brisbane: The University of Queensland. url: https://slcladal.github.io/topicmodels.html (Version 2024.04.22). There code and explanations can be found here. Setup setwd("../r_code/") # install the required pacakges # install package...

11637 sym R (24059 sym/61 pcs) 5 img

Natural Language Processing

01.10.2024

Introduction This is example code from Simon’s AI workshop which explores NLP and its reseaerch uses. See Simon’s GitHub page for more information. From Simon’s document - In this lab, we will introduce tools for natural language processing (NLP), from basic data preparation through to some exploration and building a simple machine learning m...

10104 sym R (16856 sym/75 pcs) 7 img

Partial Dependence Plot DALEX Workflow

12.09.2024

Introduction This document contains a draft workflow to building random forests and PD/ICE plots. The workflow includes examples to color the ICE plots by variables. Stack Overflow Examples The Ames Housing dataset is from De Cock (2011). It has 82 fields were recorded for 2,930 properties in Ames IA. This version is copies from the AmesHousing pa...

807 sym R (15466 sym/67 pcs) 6 img

Introduction to Tidyverse

14.06.2024

Introduction to Tidyverse This code is a brief introduction to Tidyverse. Adapted from the Guide to R Book available at the following link. Tidyverse is a group of packages (dplyr and ggplot2) that can be used for data management, cleaning, and initial visualizations. Set up Set up your working directory and load the appropriate packages. # set wo...

5943 sym R (17392 sym/64 pcs)

HMA Conflict - Data Cleaning

18.04.2024

Introduction This file and code consolidates my data cleaning steps into one document. This file does not include any analysis steps. setwd("~/Desktop/University of Utah PhD /Research/r_code") Country Level Dataframe ## Reminder this data *INCLUDES* imputed conflict counts which was completed in excel hma.con.df = read.csv("../data/conflict/hma_i...

1686 sym R (9969 sym/26 pcs) 2 img

HMA Conflict Modeling - Data Cleaning and Exploration

17.04.2024

Introduction This file is my working code for modelling conflict in HMA. Analysis began on March 3, 2024. Update on April, 8, 2024: Analysis of the data at the administrative boundary 1 level by country (data: hma_df_provinces_20240318.csv) ##Set working directory ##r code is the same level as data ##data has the following subfolders - conflict, ...

1642 sym R (153940 sym/195 pcs) 63 img 11 tbl

Intro the Interpretable Machine Learning (iml) package

17.04.2024

Introduction This code below works through the iml package. The code and examples are from cran’s website C-RAN-Link. Machine learning models usually perform really well for predictions, but are not interpretable. The iml package provides tools for analysing any black box machine learning model: Feature importance: Which were the most important f...

4677 sym R (6358 sym/44 pcs) 12 img

Interactive Israel - Hamas Conflict Map

30.11.2023

Introduction This interactive map was produced to display the spatial distribution of conflict events throughout Israel and Palestinian territory in Gaza and the West Bank. This data is from the Armed Conflict Location Event Database (ACLED) and was downloaded on November 29, 2023. There are a total of 5,669 events from the onset of conflict on Oct...

919 sym

Pakistan Conflict Modeling

23.04.2023

Introduction The purpose of this document is to explore different modeling approaches with the compiled Pakistan Conflict data set. The .rmd file “pak_conflict_urban_20230325.Rmd” hosts the code for data wrangling. ##Set working directory ##r code is the same level as data ##data has the following subfolders - conflict, IPUMS, NASA HiMAT, popul...

1279 sym R (171204 sym/247 pcs) 81 img 13 tbl

Intro to Self Organizing Maps

04.04.2023

Unsupervised Methods In this lab, we’ll look at how to implement two unsupervised classification methods: k-means classification Self-organizing maps The data we will use is from the Gap Minder project. While you can download the individual variables from the web site, we will use a preprocessed set of the data covering the period 1801-2018, in...

12608 sym R (43962 sym/136 pcs) 33 img 1 tbl