Write SQL query to solve given problem: What is the average salary of the worst performing managers?. Keep the solution inside sql tag ```sql [SQL-Query] ```
SELECT AVG(CAST(REPLACE(SUBSTR(T1.salary, 4), ',', '') AS REAL)) FROM employee AS T1 INNER JOIN position AS T2  ON T1.positionID = T2.positionID WHERE T1.performance = 'Poor' AND T2.positiontitle = 'Manager'