A method for monitoring and improving patient: ventilator interaction