## Hot questions for Lubridate

Categories | Question List |
---|---|

Using Lubridate in aggregate | dplyr, lubridate : how to aggregate a dataframe by week? Summing rows by month in R R aggregate a dataframe by hours from a date with time field Disaggregate quarterly data to daily data in R keeping values? Average Time Difference Between Two Dates PER Group Aggregate timeseries intervals by hour Aggregate on a daily basis in R How to aggregate weekly with uncomplete first and last week? How to remove seconds before the first full minute |

Using Lubridate in apply | Why does sapply fail to use lubridate's parse_date_time while lapply does not? Apply + lubridate returns numeric Calculating mean of a large data frame for each row based on last 15 minutes Using sapply on a vector of dates: Function very slow. Why? Apply and lubridate Change week of year value based on conditional data in other column in R Change dates on a list of dataframes Inconsistent dates formatting (lubridate fail) Why does lubridate mdy() return an error in lapply()? How can I convert to data from filenames in a list? How to split epochs into year, month, etc apply condition if val for continuous minutes Time differences between adjacent time stamps in R Converting a list of dates into another format in R? Using lapply to output values between date ranges within different factor levels Grouping data and applying functions to the grouped data |

Using Lubridate in chron | How to convert date to the closest weekend (Saturday) R: Cut datetimes by time of day weekend dates within an interval R Reorder time series into a custom 'quasi-chronological' order lubridate hour doesn't handle chron times Force chronological calendar month levels in R |

Using Lubridate in data manipulation | convert multiple timezones into one - r ifelse with three conditions Split & Extract date (Free form writing) and hours mentioned as numbers into separate columns - R datatable not create correct value when using date to calculate Evaluate Time Between Elements of Row |

Using Lubridate in datatable | Calculate duration of a time interval within a given period Convert monthly data from one type to another R - How to format the date of several columns in a datatable/dataframe Find dates within a period interval by group How do I prevent {data.table}foverlaps from feeding NA's into its any(...) call when executing on large datatables? Find duration by hour |

Using Lubridate in duration | duration {lubridate}: Can durations be negative? How to add hours with lubridate without specific dates, and not over 24h? Calculate Duration Omitting Overlapping Dates in R Is it possible to print a duration with HH:MM:SS format? R: ggplot with durations ISO 8601 extended duration format PnYnMnDTnHnMnS in R lubridate::duration("minutes") returns an error when duration less than 60 seconds R - lubridate: split durations into "sub-durations" How to calculate a duration of a dttm variable? I want to assign "day" and"night" variables based on maximum duration inside and outside "08:00:00-20:00:00" Reading time duration with dplyr or lubridate Error with durations created from a data.table using lubridate & dplyr Group, take duration and set condition within R (dplyr, r) Format lubridate duration column for axis labelling Duration in seconds since midnight on specific day lubridate convert decimals into months R as.difftime() issue for times longer than 1 day |

Using Lubridate in for loop | Looping through a data frame of datetimes How to transfer milliseconds from POSIXct to another POSIXct based on a third column in r string manipulation using ifelse within a for loop Joining two dataframes where a date in one falls into an interval in another. R |

Using Lubridate in if statement | Checking if there exists a value in vector of dates that lies within a given range Date manipulation with lubridate and if-statement Delete all times less than a specified value maintain POSIXct time format with ifelse and dplyr Conditional Statement Not Working |

Using Lubridate in loops | Looping through date in R loses format Create start and endtime columns based on multiple conditions in R (dplyr, lubridate) Check previous row in datetime, if time is greater than a certain value, place in a group and take its duration in seconds (R, dplyr, lubridate) Outputting various subsets from one data frame based on dates |

Using Lubridate in mutate | Combining dplyr::mutate with lubridate::ymd_hms in R randomly causes segfault Calculating age using mutate with lubridate functions Mutate_if or mutate_at in dplyr with Dates How to use lubridate as_datetime function in combination with dplyr mutate and case_when functions? Using the result of summarise (dplyr) to mutate the original dataframe Using mutate with dates gives numerical values Change Date Format from %y-%m-%d %h:%m:%s to %Y%M%D with lubridate and mutate Mutate based on two conditions in R dataframe mutate_at to date across multiple tibbles R dplyr::mutate_ and lubridate::parse_date_time Standard Evaluation not working together as expected dplyr : mutate and find next business day? Changing time zone on all timestamps using mutate_if and force_tz Autoincrement by set amount in dataframe with mutate? Using lag in mutate() on a arranged data Categorising Time in different slots using R mutate_impl error in dplyr/lubridate add date time Find the continuous running days of an engine |

Using Lubridate in parsing | Parsing complicated date column parsing date times in dplyr Parsing 12-hour times using lubridate Parsing/formatting odd date formats with lubridate Parsing Dates from Text in R Parsing dates with parse_date_time: Why does "2004-04-04 02:00" fail? Removing date part from timestamp in R lubridate date parsing for dates starting with 0 parsing compacted date times where no separating character between year and hour lubridate parsing vector of strings results in todays date Parsing dates in multiple formats in R using lubridate How can I explain to lubridate which locale it should use? why won't lubridate work in shiny? Date parsing of character vector ("Month-Year") |

Using Lubridate in purrr | Check if current date is between date period interval and export the result for each date on separate excel sheet how to break a time range into monthly queries? How do I get a ggplot to start the x axis from specific month Creating a df of dates to pass onto a purrr function R: Iterating over a series of dates to create multiple intervals |

Using Lubridate in regex | Extract year from string and text data R: how to extract full date from year week? Subtract days from a date in a text field Date containing weekday/Month/Day/Year can't be correctly parsed by Lubridate Conditionally extract and change the date in date field |

Using Lubridate in shiny | shiny: conflict between lubridate and shinyjs when using show method? Unable to correctly filter by dates in a Shiny app Shiny Dynamic sliderInput displaying warning when min and max dates are dynamically generated from other UIs RShiny - Same time last year |

Using Lubridate in stringr | Trying to combine dates and times date format within dataset column in R How to coerce date type for variables in dataframe using dplyr and a helper function in r? Merging values from 2 different datasets within a certain time interval into a single dataset (R) |

Using Lubridate in strptime | convert to date and strip time? How to convert decimal time to time format R: Get workweek number, not seven day periods since Jan 1st strptime range and make a date column Start the Weeknum on Sunday as the first day of the week |

Using Lubridate in subset | Subset dataframe based on POSIXct date and time greater than datetime using dplyr Subset the same period of time for different years Does lubridate not like subsetting? How to calculate time interval for a subset? R subset today data with lubridate How to take subsets of lists in a tibble Subsetting by year gives different results using ymd() vs. year() how to subset POSIXct from POSIXct range Subset specific dates (year and month) from data.frame Subset dates with a given weekday and select next date if weekday is missing R: How do I subset based on conditional DateTime data subset random quarter time data from a lubridate dataset |

Using Lubridate in tibble | Joining two data frames with intervals misbehaves? ifelse() function - refer to the following day Tibbles reject lubridate's duration and period objects Replace future dates with NA using dplyr Time zone gets lost with lubridate when creating a new datetime component from it Hour/minute adds one hour from datetime with lubridate Create 24 columns and a dummy if timespan overlaps with hour |

Using Lubridate in tidyr | Tidyr's gather() with NAs Split a Column Into 2 Using Regular Expression Convert a a character column to date with multiple formats Transform "start stop data" (a.k.a. turn codes) into long format (a.k.a. time codes) with dplyr Matching values between data frames based on overlapping dates Matching Columns with Overlapping Intervals (lubridate) replace duplicate dates with weekly sequence order in R |

Using Lubridate in timezone | lubridate 1.7.3 error: CCTZ: Unrecognized timezone of the input vector: "" with_tz with a vector of timezones Adding lubridate dates to vector changes timezone and thus date R: lubridate's dst() not working as expected lubridate: inconsistent behavior with timezones Convert to local time zone from latitude and longitude R Read character datetimes without timezones R: `lubridate` cannot recognise timezone "SG" in Windows formatting date and timezone in R R lubridate: Why do I get a "unknown timezone" error? How can I add time to a date time data frame with unknown time zone |