I hereby claim:
- I am srikumarks on github.
- I am srikumarks (https://keybase.io/srikumarks) on keybase.
- I have a public key ASDxkdOO0jW8Il1zHH4CO79kv6lEx4tXYvlOA9CosHx7WAo
To claim this, I am signing this object:
### A Pluto.jl notebook ### | |
# v0.19.42 | |
using Markdown | |
using InteractiveUtils | |
# This Pluto notebook uses @bind for interactivity. When running this notebook outside of Pluto, the following 'mock version' of @bind gives bound variables a default value (instead of an error). | |
macro bind(def, element) | |
quote | |
local iv = try Base.loaded_modules[Base.PkgId(Base.UUID("6e696c72-6542-2067-7265-42206c756150"), "AbstractPlutoDingetjes")].Bonds.initial_value catch; b -> missing; end |
import re | |
from pypdf import PdfReader | |
import pandas as pd | |
# 34ca61ebc3ddbb71a1d16f8f43db38d031872126 encashment-details.pdf | |
encashment = PdfReader("encashment-details.pdf") | |
# 11e0aff1007065d9a4de49ac5499fbf4186dcda0 purchaser-details.pdf | |
purchaser = PdfReader("purchaser-details.pdf") |
function mandelbrot_kernel(c, max_iter) | |
z = c | |
for i in 1:max_iter | |
z = z * z + c | |
if abs2(z) > 4 | |
return i-1 | |
end | |
end | |
return max_iter |
using Dates, TimeZones, SatelliteToolbox | |
""" | |
upcoming_birthpos gives you the exact time and date within the | |
next year, at which the earth arrives again closest to where it | |
was when you were born (relative to the sun). It also gives | |
this minimum distance value in km. | |
""" | |
function upcoming_birthpos(y,m,d,h,min,s,tzstr="Asia/Kolkata") | |
dob = ZonedDateTime(y,m,d,h,min,s,0,TimeZone(tzstr)) |
:- module(qd, [gendata/0, nth/5, weekday/2, direction/2, dayprop/2, today/1, gendates/4, leapyear/1, nonleapyear/1, validate/1, cardinal/3]). | |
:- use_module(library(clpfd)). | |
% This module defines a small query language for (approximate) dates according | |
% to the gregorian calendar. You can run this program using -- | |
% swipl -t gendata datelang.pl | |
% Abstract | |
% ======== |
using DataStructures | |
# Ref: https://github.com/renatoathaydes/prechelt-phone-number-encoding | |
# This is a straight translation of Norvig's program into Julia. | |
# Function for function it is a straight port. | |
mappings = [("eE",0),("jnqJNQ",1),("rwxRWX",2),("dsyDSY",3),("ftFT",4),("amAM",5), | |
("civCIV",6),("bkuBKU",7),("lopLOP",8),("ghzGHZ",9)] | |
char2num = Dict((l,d) for (s,d) in mappings for l in s) |
// Usage is like - | |
// | |
// let x = await task(obj, obj.method, arg1, arg2); | |
// do_something(x); | |
// | |
// where obj.method is a method that takes a NodeJS style callback | |
// as the last argument, which is left out when making the above call. | |
// The task function turns the callback backed function into a | |
// pseudo promise which the async/await mechanism can work with. | |
function task(target, fn, ...argv) { |
I hereby claim:
To claim this, I am signing this object:
// metric = array of real numbers (like > 100 or something) | |
// IQR = inter-quaartile-range | |
function numBins(metric, defaultBins) { | |
var h = binWidth(metric), ulim = Math.max.apply(Math, metric), llim = Math.min.apply(Math, metric); | |
if (h <= (ulim - llim) / metric.length) { | |
return defaultBins || 10; // Fix num bins if binWidth yields too small a value. | |
} | |
return Math.ceil((ulim - llim) / h); | |
} |