This blog post is a follow up to our earlier ELI5 (part one): Setting up a Melon fund and becoming your fund’s first investor. If you haven’t read that post yet, that’s the place to start! The below assumes that you set-up, and invested in, your fund.

Today we’re going to walk you through trading within your fund, entering orders and cancelling limit orders.

Before getting started…

Before getting started, make sure you are logged into frame and connected to the MMI with the same wallet you used to create your fund. This will ensure that you can trade on behalf of your fund. If you’re already logged in with your wallet, you can skip this section.

Plug your hardware wallet into the USB port of your computer and log into the device.

Select the Ethereum app on your hardware wallet.

Open the Frame application on your computer click on the Ledger logo and then select the account you’d like to use.

Open the Melon Manager Interface application on your computer.

After a few seconds a warning message will pop up explaining the legal issues you should consider before proceeding. When you have read this and are happy to proceed click OK.

Click Your Wallet in the top-right-hand corner of the MMI window.

You should see a request in your Frame application from the Manager Interface, click Approve.

On the Melon Manager Interface you should now see an option saying: “Use … from Frame“, click this.

Click Go to Your fund. The Trading window of your Melon fund will appear.

Navigating your way around the Fund

On the left of your fund window the Holdings section shows what assets your fund currently holds. For example in the image below we can see that the fund holds 0.75 WETH. The prices of assets are denominated in ETH. The list only shows the assets that you included in your asset universe during the fund set up because these are the only assets the manager will be allowed to trade (investors pre-agree to this up-front).

Order-books

When you click on an asset in the holding lists, an order-book for that asset against WETH will load. This shows the aggregated limit orders active across the DEXs for whichever asset pair you have selected. Below you can see the BAT/WETH order-book.

The check-boxes can be used to filter out liquidity on different exchanges. If you have not selected one of these exchanges in the “set up” phase of your fund, you will not be able to see the order book or trade using that exchange.

Placing your first trade

As a first trade, how about we buy some BAT at market price. You can create a market order ticket by simply clicking on the best offer in the order book (highlighted below).

The order-book information from this offer (exchange, price, quantity) automatically populates into a trade ticket as per image on the left.

As a market order, you can change the desired quantity, but not the price. The Total WETH field will then update to reflect the order details.

When you’ve checked and confirmed the trade details, you can click on BUY (or SELL).

You will now need to confirm the transaction.

Reminder: As discussed in Part One: the gas price defaults to 5 GWEI. If the Ethereum network is busy this will not be enough to get your transactions mined in a timely manner. It’s always worth clicking on the Eth Gas Station link before you proceed.

You will now need to sign the transaction in Frame.

Once you’ve confirmed the transaction, the Melon protocol checks to see if this fund is abiding by the fund rules before it allows the transaction to proceed. This is called the pre-trade check.

The Pre-trade check

Now you’ve placed your order, but the beauty of the Melon protocol is that it’s designed to protect investors by ensuring the manager behaves “as promised”. The pre-trade check scans your risk management ruleset and, only if you are not breaking any of them, it lets you proceed.

The pre-trade checks depend on how the fund was configured at the “set up” phase (Part I) but includes things like:

Is this an asset that the manager is allowed to hold?

Is the position size going to be larger than the promised maximum size after making this trade?

Is the manager trading with an exchange that he/she is allowed to trade on?

Is the price the manager is trading at “reasonable” or does it look suspicious?

All of the answers to these questions have to check positive before the protocol allows the trade to go through. If they do, the trade should be successful and you should see your position holdings update shortly afterwards:

That’s your first order successfully entered and executed and you are now long BAT tokens in your fund!

Now, there will be times when the market price is not attractive and you want to place a limit order to guarantee that if you trade an asset, you get it at the price you want.

Placing a Limit order

Okay, so now we’re going to buy some DAI using a limit order.

Check that you are still logged in to your Ledger to avoid a No Signer Found Error.

Then click on the Limit tab and make sure that is selected as below.

Note: Do not click on any of the prices in the public order-book. Doing so reverts the order type to Market!

Select the token you want to trade.

Again, the Exchange field shows which exchange you are about to trade on. You can change the specified exchange using the drop-down before submitting the order but you should check the available liquidity on that exchange using the tick boxes in the public order-book before you do so!

You’ll need to edit the Price and Quantity fields for your order as per the image.

The Total WETH field will then update to reflect the order size.

When we’ve configured the order ticket and checked the details we can then click on BUY (or SELL).

Confirm the transaction details and sign the transaction in Frame.

Once that’s done you should shortly see your order appearing in your Open Orders table at the bottom-right-hand corner of the MMI.

You should also be able to see this working in the public order-book.

Trading on the Melon Engine

The Melon Engine is a unidirectional market which only bids for MLN. The Melon Engine smart-contract amalgamates AMGU (asset management gas) from users on the network in WETH and later uses them to bid for MLN. The more WETH in the contract, the higher the price the Melon Engine is willing to pay for the MLN. Every 30 days the frozen WETH in the Melon Engine can be thawed by calling the thaw function and made available exclusively for Melon managers to trade or arbitrage (!).

If you’d like to buy discounted ETH from the Melon Engine against your MLN, select the Melon Engine in the exchange dropdown of the trading form.

Note, the Melon Engine smart contract address is: 0x7caec96607c5c7190d63b5a650e7ce34472352f5.

Anyone is able to call this function at the end of every 30 day period to make the tokens available in the Melon Engine.

Open Orders (your orders)

Here you can see your open orders (orders that have not been filled yet).

Cancelling an order

If you change your mind about a limit order or want to cancel the order for any other reason, you can cancel an order.

Check that you are still logged in to your Ledger to avoid a No Signer Found Error.

Click on the circled cross to the right of the order you want to cancel, in the open orders tables.

Confirm the transaction details and sign the transaction in Frame.

When that’s been processed the order should disappear from your Open Orders.

Visualising historical fund data

Over time, you’ll likely want to know how your fund is performing since inception (or over any other time period) and you might even want to know how it’s performing compared to other funds on the platform.

Other times, you might just like to analyze the historical data related to your fund. For example, what trades did you do? how successful were they? Which exchanges have you been using the most? This is all possible on the Melon Monitoring tool which we built leveraging The Graph protocol (more on that here). All you need to do is search for your fund, click on it and all this historical data is right there presented to you right there.

Coming soon…

There are currently 11 tradable tokens in the asset universe and we’re working to include more. We are also working on integrating more DEXs for Melon funds to trade on, which should provide greater liquidity. This should help improve your experience AND your performance. Stay tuned!

In ELI5 Part III, we’ll explore investing in other funds, redeeming from a fund and shutting down a fund!