```\nfunction getPositionValue() public view returns (uint256) {\n    uint256 markPrice = getMarkPriceTwap(15);\n    int256 positionSize = IAccountBalance(clearingHouse.getAccountBalance())\n        .getTakerPositionSize(address(this), market);\n    return markPrice.mulWadUp(_abs(positionSize));\n}\n\nfunction getMarkPriceTwap(uint32 twapInterval)\n    public\n    view\n    returns (uint256)\n{\n    IExchange exchange = IExchange(clearingHouse.getExchange());\n    uint256 markPrice = exchange\n        .getSqrtMarkTwapX96(market, twapInterval)\n        .formatSqrtPriceX96ToPriceX96()\n        .formatX96ToX10_18();\n    return markPrice;\n}\n```\n