This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
limit = 100; | |
s = "TotalRevenue"; | |
prop[p_String] := prop[p] = EntityProperty["Company", p]; | |
c[e_, p_String] := c[e, p] = CompanyData[e, p]; | |
ind[e_] := ind[e] = c[e, "Industry"]; | |
m[e_, p_String] := m[e, p] = Not@MissingQ@c[e, p]; | |
es[n_Integer, p_String] := | |
es[n, p] = | |
EntityList@EntityClass["Company", {prop[p] -> TakeLargest[n]}]; | |
sel[n_Integer, p_String] := sel[n, p] = Select[es[n, p], m[#, p] &]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
With[{ | |
time = {{2020}}, | |
ents = Table[ | |
CompanyData[FinancialData[s, "Company"], "Industry"], {s, | |
Select[ | |
EntityList[ | |
EntityClass[ | |
"Financial", {EntityProperty["Financial", "MarketCap"] -> | |
TakeLargest[100]} | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
With[{ | |
a = "SPXL", | |
b = "VIXY" | |
}, | |
With[{ | |
apath = FinancialData[a, "Close", All]["DatePath"], | |
bpath = FinancialData[b, "Close", All]["DatePath"] | |
}, | |
With[{ | |
adiff = Transpose[{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cat segment1_0_av.ts segment2_0_av.ts segment3_0_av.ts > all.ts | |
ffmpeg -i all.ts -acodec copy -vcodec copy all.mp4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# First Draft | |
{{e, o, e, o, e} :> C[1], {e, o, e} :> C[2], {e, o, e, o, e, o} :> C[3]} | |
# More concise story | |
{{e,o} :> C[1]} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# broken for now - just hangs | |
#qemu-system-x86_64 -serial mon:stdio -d cpu_reset -d guest_errors -smp 4 -m 1024 -s -machine q35 -device ich9-intel-hda -device hda-duplex -net nic,model=e1000 -net user -device nec-usb-xhci,id=xhci -device usb-tablet,bus=xhci.0 -cpu qemu64 -drive file=harddrive.bin,format=raw |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def compose(*fns): | |
return functools.partial(functools.reduce, lambda v, fn: fn(v), fns) | |
example = compose(baz, bar, foo) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Wolfram Axiom | |
- {\!\(\*SubscriptBox[\(\[ForAll]\), \({\[FormalA], \[FormalB], \[FormalC]}\)]\(\((\((\[FormalB]\[CenterDot]\[FormalC])\)\[CenterDot]\[FormalA])\)\[CenterDot]\((\[FormalB]\[CenterDot]\((\((\[FormalB]\[CenterDot]\[FormalA])\)\[CenterDot]\[FormalB])\))\) == \[FormalA]\)\)} | |
# Subtract and branch if less than or equal to zero | |
- subleq a, b, c ; Mem[b] = Mem[b] - Mem[a] - if (Mem[b] ≤ 0) goto c | |
# Universal Iota combinator | |
- {\displaystyle \iota :=\lambda f.((fS)K)} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FindEquationalProof[ | |
\!\( | |
\*SubscriptBox[\(\[ForAll]\), \({\[FormalA], \[FormalB]}\)]\( | |
\*OverscriptBox[\(\[FormalA]\[CircleTimes]\[FormalB]\), \(_\)] == | |
\*OverscriptBox[\(\[FormalA]\), \(_\)]\[CirclePlus] | |
\*OverscriptBox[\(\[FormalB]\), \(_\)]\)\), | |
AxiomaticTheory["BooleanAxioms"] | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{\[Gamma], 93}, {\[Beta], 67}, {\[Alpha], 72}, {B, 29}, {A, 45}, {F, | |
28}, {\[Delta], 65}, {\[Zeta], 38}, {e, 13}, {o, 1}} | |
{ | |
{e, o, e, o, e} :> \[Alpha], | |
{e, o, e} :> \[Beta], | |
{\[Alpha], o} :> \[Gamma], | |
{e, e} :> \[Delta], | |
{\[Beta], \[Beta]} :> \[Zeta], | |
{e, \[Gamma]} :> A, |