finish matrix doc