There are few verbal connections between the story of Jonah and Genesis 4.
In Jonah 2:5, from the belly of the whale Jonah cries, “I am driven out from before your eyes!” (נִגְרַשְׁתִּימִנֶּגֶדעֵינֶיךָ). This echoes the complaint of Cain in Genesis 4:14: “Hey! You have driven me today from before the face of the land and from you I will be hidden!” (הֵןגֵּרַשְׁתָּאֹתִיהַיּוֹםמֵעַלפְּנֵיהָאֲדָמָהוּמִפָּנֶיךָאֶסָּתֵר). When Jonah sees that Nineveh has repented and God has relented from destroying the people, the text says, “It seemed an exceedingly great evil to Jonah, and he became angry” (וַיִּחַרלוֹ Jon 4:1ֹ, see also Jon 4:4, 9). After God rejected Cain’s sacrifice, the text says, “Cain became exceedingly angry” (וַיִּחַרלְקַיִןמְאֹד Gen 4:5). A few more: Just as God confronts Cain with a question after his crime (Gen 4:9), so also God confronts Jonah with a question in Jonah 4:4. In both stories God, at some point, confronts the antagonist with the issue of “doing good” (אִם־תֵּיטִיב Gen 4:7 ; הַהֵיטֵב Jon 4:4, 9). Finally, both Jonah and Cain “settled to the east of” (וַיֵּשֶׁבבְּאֶרֶץ־נוֹדקִדְמַת־עֵדֶן Gen 4:16 ; וַיֵּשֶׁבמִקֶדֶםלָעִיר Jon 4:5). What is the significance of making a connection between Jonah and Cain? Making the connection at the beginning of Jonah 4 casts another dark shadow over the character of Jonah. If you have entertained any notions—perhaps because of the prayer in chapter 2—that Jonah is the good guy, those thoughts are drowned by the recollection of Cain. Remembering Cain at this point in the story also foreshadows what is to come. Jonah doesn’t recover. Hatred and bitterness have their way with him (Jon 4:9).
I am not claiming that this connection was necessarily intended by the author of Jonah. Whether it was intended or not, making the connection produces a more colorful reading. After all, the characters (Jonah and Cain) are similar in the end.