> For the complete documentation index, see [llms.txt](https://docs.sterlinglabs.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sterlinglabs.co/portfolio/trade-log-and-activity.md).

# Trade Log and Activity

The **Trade Log** and **Activity** tables sit beside Positions in the tables card on the Overview. Both share the brokerage scope chips in the page header and page at 10, 25, or 50 rows.

## Trade Log

One row per execution. A partially filled order appears as one row per fill. The default order is newest first.

| Column                | Meaning                                                                                                                                                                                                         |
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Date**              | When the trade executed.                                                                                                                                                                                        |
| **Side**              | **BUY** or **SELL**.                                                                                                                                                                                            |
| **Symbol**            | The instrument.                                                                                                                                                                                                 |
| **Quantity**          | Shares or contracts in this execution.                                                                                                                                                                          |
| **Average price**     | On a buy, hover shows your average cost basis after this trade. On a sell, hover shows the average cost basis the sale is measured against.                                                                     |
| **Amount**            | Quantity times price.                                                                                                                                                                                           |
| **Position Δ**        | How much this trade changed the position, as a signed percentage. Selling a quarter of a holding reads −25%.                                                                                                    |
| **Live P\&L**         | The lot's current gain or loss at its valuation price: Sterling's live price where one exists, otherwise your broker's mark. Hover shows how fresh the mark is, or, for a closed lot, that the figure is final. |
| **Realized P\&L**     | On sells: the gain or loss locked in by this sale. A dash with a reason appears when it cannot be computed.                                                                                                     |
| **Unrealized P\&L**   | On buys: the gain or loss, at the valuation price, on the units from this purchase that are still held. A fully closed lot shows a dash with "nothing left to mark."                                            |
| **Cost Basis Method** | How P\&L is measured; see below.                                                                                                                                                                                |

Closed lots are dimmed. The **Type of asset** and **Sectors** filters at the top of the page apply to the Trade Log as well as to Positions.

### How profit and loss is measured

The P\&L headers carry an information note reading **Average cost basis, gross of fees.** Realized figures use average cost, every figure is gross of fees, and the buy-row unrealized figure is the one exception described below.

* **Average cost** means each sale is measured against the average price you paid for the shares you held at the time, not against specific lots. Your broker's tax lots may use a different method, so realized figures can differ from your broker's tax reporting. The unrealized figure on a buy row is different in kind: it marks the units from that purchase that you still hold, so you can see how each purchase is doing.
* **Gross of fees** means commissions and fees are not deducted. Brokers report fees inconsistently, so Sterling shows the gross figure rather than an uneven net one.

## Activity

Every settled event on your accounts in one stream: buys and sells, deposits and withdrawals, dividends and stock dividends, fees, interest, tax, transfers in and out, and corporate actions. The most recent hundred events load first.

| Column     | Meaning                                                                                                                                                                                                                                                                |
| ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Date**   | When the event settled.                                                                                                                                                                                                                                                |
| **Type**   | The kind of event. Credits are green and debits red. A dashed outline means Sterling inferred the category because the broker did not label it; hover reads "Category inferred by us, not your broker. The activity is real and settled — only the label was guessed." |
| **Symbol** | The instrument, or the currency for a cash event.                                                                                                                                                                                                                      |
| **Units**  | Shares or contracts, where applicable.                                                                                                                                                                                                                                 |
| **Price**  | The execution price, where applicable.                                                                                                                                                                                                                                 |
| **Amount** | The signed cash effect, colored by direction.                                                                                                                                                                                                                          |
| **Fee**    | Any fee your broker attached.                                                                                                                                                                                                                                          |

Only the brokerage scope applies to Activity; cash events have no sector or asset type to filter on. Before anything has settled, the table reads **No activity yet. Dividends, fees and transfers appear here.**


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.sterlinglabs.co/portfolio/trade-log-and-activity.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
