Skip to content

Instantly share code, notes, and snippets.

ueliwechsler

Block or report user

Report or block ueliwechsler

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ueliwechsler
ueliwechsler / workingWithDateTimes.jl
Created Jul 5, 2018
Shows some ways, how to work with DateTime format in Julia. #Julia #DateTime #time, #Dates
View workingWithDateTimes.jl
year, month, day = Dates.yearmonthday(now(Dates.UTC)); hour = Dates.Hour(now(Dates.UTC))
timeNow = DateTime(year,month,day,hour)
utc_start = [timeNow:Dates.Hour(1):timeNow+Dates.Hour(n-1)...]
timeNow = now(Dates.UTC)
utc_start = [Dates.format(value, "yyyy-m-dd HH:00:00") for value in timeNow:Dates.Hour(1):timeNow+Dates.Hour(n-1)]
@ueliwechsler
ueliwechsler / readJSON.jl
Last active Jun 21, 2018
Julia: read .json to strict #Julia, #JSON
View readJSON.jl
using JSON
file = normpath(joinpath(@__DIR__,"..\\dsl\\historic_query.json"))
dict = open(file, "r") do f
dict = JSON.parse(f)
end
You can’t perform that action at this time.