<h4>Chapter 21: < algorithm trading ></h4>
Luckily, Yoon Gihwan’s studio wasn’t far from Woosung’s ce. He found it odd why he didn’t live in a multi-bedroom apartment, but as soon as he walked in, he understood.
“Do you live apart from your family?”
“My son and wife live abroad. My son was being bullied at school, so I wanted him to get away from that.”
“… Oh.”
“You don’t have to pity me. This ce is wonderful.”
Yoon Gihwan was right. The studio was clean and well organized. Even the kitchen shone without a spot of grease. Woosung saw the books he kept around a shelf and asked.
“Did you read all these?”
“I’ve got nothing else to do, so I read a lot.”
Over a hundred IT rted books lined the shelves. Woosung picked up a few books. Some titles included “Maintenance and Use of Linux,” “Object-Oriented Programming,” “Clean Codes,” and “Use of Oracle Database.”
“You brought your work home…”
“How could I not? Learning never stops. If you don’t continue improving your skills, you won’tst long in this field.”
Woosung nodded to his good sense.
“Well, that’s about it for our small talk. Let’s begin our session.”
“Sure. Go ahead.”
Woosung brought out a whiteboard and wrote a few equations.
Call Option equation c=SN (d1) – X e – rT N (d2).
Put Option equation p = Xe – rTN(-d2) – SN(-d1).
What Yoon Gihwan wrote was the ck-Scholes equation. It was something Woosung hasn’t seen since university.
“This is the foundation of the options market. Myron Scholes received the Nobel prize for Economic Sciences in 1997 for this. This is an example of an algorithm.”
Woosung remembered reading about it.
“But even this equation was useless on October 19, 1987, the ck Monday.”
“Wow! You have been studying. You’re right. The possibility of Dow Jones dropping 7% was mathematically 0%. When it happened, the ck’s system froze, and people became frantic. They ended up all selling, which caused a drop of 25%. No one could do anything.”
“ck said you may calcte the stars’ movements, but you can’t guess people’s reactions.”
Yoon Gihwan eximed.
“Wow! You will make a great student.”
“He was originally a mathematician butter turned to economics and financial consulting.”
“That’s right. He became well known in economics. The stock market used this equation like its the golden rule.”
Yoon Gihwan then added more names to the whiteboard.
-David Shaw
-Jeff Bezos
Jeff Benzos was the founder and chairman of Amazon. David Shaw was less well-known, but Woosung remembered reading about him in the book.
“He is the founder of D.E. Shaw. Jeff Bezos is one of David Shaw’s quants. He quit that job andter founded Amazon.”
Again, Yoon Gihwan was wowed.
“You never disappoint me! If I may add, David Shaw was a geniusputer scientist. At the time, talented traders were mostly mathematicians or statisticians. At first, no one paid attention to thisputer scientist in stock trading.”
“He suggested an algorithm of his own, which Morgan Stanley rejected at the time.”
Yoon Gihwan nodded.
“So you read up on the history. Then, myst question is this. Why did I mention these three names?”
“There are many types of quant. Some focus on making the algorithm while others specialize in theputer aspect of it. David Shaw used theputing power to increase the speed of the algorithm, while Fischer ck showed talent in creating the algorithms.”
It was a difference between the creator and the user, and rarely, some were talented at both.
Yoon Gihwan put down his marker and asked.
“What do you think you are?”
“I am…”
Woosung became quiet. This was something he considered intently while reading the history of algorithm trading.
Choose and focus.
He only had a limited amount of time, so he had to make quick choices and focus on them. It was true he was smarter, but he wasn’t a robot. He also didn’t want to be a money-making machine. He wanted to exercise to be healthier and enjoy life while making good money. This was after his revenge though. Until then, he was ready to sacrifice everything.
“I n on doing both. I will make the algorithm and use it myself to be sessful.”
Woosung’s eyes looked crazy. Yoon Gihwan flinched at Woosung’s determination. It looked like Woosung was ready to do whatever was necessary, even murder. Yoon Gihwan knew he couldn’t stop Woosung. It seemed pointless to tell him how hard it would be.
“I…I see.”
Yoon Gihwan was expecting Woosung to choose one or the other, but now he could only nod to Woosung’s answer.
“I n on continuing to study statistics and mathematics. All you need to teach me is what you learned from your experience.”
Woosung understood statistics and mathematics were the foundations of creating algorithms.
“Oh, I see.” Yoon Gihwan nodded.
***
Yoon Gihwan stopped asking questions and continued to exin his own past works.
“At first, it was a very simple system. When the golden cross urred, we bought, and when the death cross urred, we sold.”
Golden cross.
It was a technical indicator urring when the short term moving average crossed above the long-term mark. When it urred, it meant there was a change of stock gains on the horizon.
On the other hand, death cross was a sign that short-term momentum in stock was slowing. It happened when a stock’s short-term moving average fell below its long-term moving average.
“That was very simple.”
“But it was still better than manual trading. Nobody could be as methodical as aputer system.”
Woosung agreed. He learned this as the chief of the server team at Bitmain.
“Next must be something moreplex.”
“Yes. We added more guidelines for the algorithm to follow including the candlestick patterns.”
“So basically, you used the trend to follow a strategy?”
“Yup, but then we came to a problem.”
“Spaghetti code.”
Spaghetti code.
It referred to the unstructured and difficult-to-maintain source code. To exin it simply, it was as if someone drew a yellow line on top of a ck line, which they ced on top of a blue line.
“Yes. We also tried to add indicators like MACD and Stochastics, which made it even harder. Refactoring these codes alone took over a month.”
“And following the rules everybody already knew wouldn’t have made you a lot of money.”
Yoon Gihwan nodded and wrote more words on the board.
“So we read the rted academic articles. We wanted to make an algorithm the experts in the field already used but an average trader wouldn’t know.”
Yoon Gihwan paused and looked at Woosung. He was challenging Woosung to guess the answer. Woosung contemted.
“Are you referring to the pairs trading strategy?”
Yoon Gihwan was again impressed.
“You probably didn’t have a long time to study, yet you did well.”
“Anything is better than dying.”
Yoon Gihwan shuttered at Woosung’s dark tone, but he quickly recovered and continued.
“Yes. We used the pairs trading strategy.”