```{r setup, include=FALSE}
knitr::opts_chunk$set(
  results = 'asis',
  echo = FALSE,
  warning = FALSE,
  message = FALSE,
  fig.align = 'center'
)

#Load libraries
library(tidyverse)
library(gapminder)
library(kableExtra)
library(readxl)
```


# Introduction
Before Data School I was focused within the Molecular/Micro Laboratory space where our team is involved in looking at the effects of different diets on the gut microbiome. Spending the majority of my time developing and optimising molecular assays I have no prior background in either R or coding.

# My Project

The main goal I wanted to achieve with my data was to practice the R skills I have learnt within Data School and to experience wrangling 16S Sequencing data.

**Example of code used to create my Table**
```{r mytable, out.width='50%', echo = T}

library(readxl)
Data <- read_xlsx("../Data/VAN_Data.xlsx")

knitr::kable(head(Data, n = 5), format = "html", caption = "Section of 16S Sequencing VAN data") %>% 
  kable_styling("striped")
```

## Preliminary results

Rather than demonstrating the results of the project, I wanted to present a glimpse of what I have learnt to do within R.






**Example of a Plot from R**

```{r Plot, out.width='60%', fig.align='center', fig.height= 4, fig.width=6, fig.cap="ggplot of Data Sample"}

Data <- read_xlsx("../Data/VAN_Data.xlsx")
VAN_rep <- Data %>% 
  group_by(Method) %>% 
  select(-Sample) %>% 
  #summarise(median(Participant))
  unite(repname, c("Participant","Replicate"))
VAN_long <- VAN_rep %>% 
  gather(key= Phylum, value = Count, -repname, -Method) %>% 
  mutate(Count = log10(Count + 1))
VAN_long %>% 
  ggplot(aes(x= Phylum, y= Count, colour = Phylum, fill = 1000)) +
  theme(legend.position = "none", axis.text.x = element_text(angle = 45, vjust = 1, hjust = 1)) +
  labs(y = "Bacterial Count", title = "Comparison of Bacterial Populations Between Different Faecal Collection Methods") +
  geom_col() +
  facet_wrap(~Method)

```




# My Digital Toolbox

I came into Data School with essentially no coding knowledge and very little experience using data so I have learnt an incredible amount during my time within Data School. These include:

* R - including packages for example dplyr, ggplot



![](resources/img/ggplot2.png){width=100px}
![](resources/img/tidyr.png){width=100px}
![](resources/img/tidyverse.png){width=100px}

## Favourite tool (rmarkdown)



![](resources/img/rmarkdown.png){.pull-right width=100px} 



# My time went ...

It really surprised me how long it took to tidy my data and just how important the initial imput of data is. In addition to this, it surprised me how versatile and powerful R can be once the data is in the correct format.  


# Next steps

There are a vast number of ways to develop the skills I learnt at Data School. I hope to refine my coding skills to be able to perform more within R and expose myself to more packages that are available within R.

# My Data School Experience

I have really enjoyed the Data School excperience. I have really enjoyed the new challenges of learning the R coding language and being exposed to new ways of analysing data. I hope to take the new skills I have learnt during my time at Data School to make some improvements within the way we manage data.
Data School has really changed the way I think about data and has challenge a lot of the previous methods I had to manage data. I feel that Data School has provided me with superior methods of handling and presenting data which I feel will vastly improve the way I analysis and present my data.  

