The psalm in Jonah 2:2-9 (2:3-10 in Hebrew) is a fine example of a thanksgiving psalm, and everything in its expression and theology would sound fine in the book of Psalms.
However, on Jonah’s lips after we have heard the narrative of chapter one, it takes a different flavour. Read in its place in the flow of this book it is ironic.