I am new with web scraping with R and will be very grateful for any help.
I am trying to scrape information from this website: https://kotis.kt.gov.lt/
My code looks like this:
#libraries
library(rvest)
library(tidyverse)
url <- "https://kotis.kt.gov.lt/"
#establish session
my_session <- session(url)
#get the form
form_unfilled <- my_session %>% html_node('form') %>% html_form()
form_filled <- form_unfilled %>% html_form_set("aid_date[from]"='2022-08-25')
results <- session_submit(my_session, form_filled)
first_page <- as.data.frame(results %>% html_elements(css = 'table') %>% html_table())
There are 21 columns in this table. However, the code is reading only 8 columns.
I will be grateful for any help.