Play Linez at

I recently ported a classic puzzle game Linez from Flash to WebGL using pixi.js. It’s free to play at on any modern mobile or desktop browser. The actual gameplay animation is a lot smoother than the GIF shown above.

Linez is a game with great depth and deceptively simple rules: align five or more same-colored tiles horizontally, vertically, or diagonally to earn points. On each turn, three new tiles are placed at random positions. Try to get as many point as possible before no more moves are available.

The site is ad-free and requires no account registration to play. Have fun and happy holidays!

BitMEX’s derivative products from Nov 2014 to Aug 2019

Since its debut in late 2014, BitMEX has launched over 180 derivative instruments. The infographic above shows a timeline of those products grouped by the underlying currency or index. Grayed-out contracts are no longer available. A few of them were intended to be short-lived, such as the B_SEGWITZ17 binary futures contract which settled on the activation of BIP141; most had been discontinued due to lack of market activities.

Among those retired contracts, the A50 series caught my attention. Unlike altcoin futures, the underlying is FTSE China A50 index, an equity index comprised of components chosen from Shanghai Stock Exchange and…

Bitwise Terminal screenshot

Bitwise Terminal is a unique command-line trading tool for BitMEX traders who value privacy and security above all others. It uses an open source Chrome extension to sign and relay API requests. This system design provides a verifiable guarantee that sensitive API credentials always stay on your computer and never get exposed to third parties including Bitwise itself.

Dayta 1.0 screenshot

I’m happy to release Dayta 1.0 ( — a simple web app that tracks the daily progress of anything. Whether you want to develop a habit or quit an addiction, Dayta can motivate you to achieve your life goals.

There’re web apps, mobile apps, and even hardware gadgets that specialize in data tracking, but none of them satisfy my needs. What I most desire for such a tool is efficiency and flexibility. …

Generate OTP (one-time password)

If you want to use Bitwise from multiple devices, you no longer have to re-type the long Bitmex API key and secret. Bitwise 1.4 now offers an alternative, more convenient way to sign in with one-time password (OTP).

When you’re signed in to your account, switch to the new “Account” tab and hit the “GET OTP” button. A 12-digit number will be revealed. 1.2 now displays USD values in tooltips

In this crashing market, a true Bitcoin maximalist would be unflustered. No matter how steeply the fiat price of Bitcoin plummets, one BTC today is still worth one BTC tomorrow. However, many Bitmex traders are accustomed to think in USD. To help them answer questions like “how much dollars got rekt today?”, 1.2 now displays USD values in tooltips as you may see in the screencast above.

USD values are calculated using Bitmex’s .BXBT index price, which derives from the latest trades at Coinbase Pro, Bitstamp, and Kraken. The price is refreshed every time you hit the GET SUMMARY button.

Sample monthly PNL summary at 1.1 has been released with monthly PNL visualization. It gives you a long-term view of your account’s performance since the first XBT deposit. Just reload the page once, hit the GET SUMMARY button, and scroll down to see the new feature.

This release also contains several bug fixes and code refactoring which have paved the way to some exciting new features I’ll announce soon. In addition to PNL visualization, 2.0 will offer automation tools that help you trade more wisely. Stay tuned.

Bitwise is a little web app that I’ve been developing to chart daily profit & loss for Bitmex crypto traders. I’m happy to announce that the website is now live at!

Bitwise is Bitmex’s missing PNL charting view

The 1.0 release displays your PNL and wallet balance for the past seven days, including unrealized gain and loss. All PNL numbers are denominated in XBT. Each color in the “PNL breakdown” section represents a specific contract type: orange for Bitcoin (e.g. XBTUSD, XBTH19 etc.), light blue for ETH, light green for BCH, and so on. …

Update: Tracking more than one habit? On mobile? Don’t miss out Dayta at

Yesterday I watched Simone Giertz’s latest YouTube video “How I managed to meditate every day for a year” and got instantly mesmerized by her newly designed Every Day Calendar — a bamboo-framed printed circuit board with gold-immersed touch pads and LED’s that keeps track of daily goals and motivates users to develop good habits.

I’ve open-sourced bitmexgo, a golang package that enables clients to call REST APIs for the Bitmex crypto trading platform. You may use it to analyze the most liquid crypto futures market or develop trading bots in Go.

Bitmex’s official golang library, which is automatically generated by swagger-codegen, turns out to be nonfunctional: due to its broken authentication flow, none of the APIs works at all. Ideally the bugs should be fixed at the swagger layer, but it appears to be a pretty thorny problem. …

Zhen Wang (crypto derivatives trading tool)

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store