Great power was with these chosen ones. Said the angel, “Look ye!” My attention was turned to the wicked, or unbelievers. They were all astir. The zeal and power with the people of God had aroused and enraged them. Confusion, confusion, was on every side. I saw measures taken against the company who had the light and power of God. Darkness thickened around them; yet they stood firm, approved of God, and trusting in Him. I saw them perplexed; next I heard them crying unto God earnestly. Day and night their cry ceased not: “Thy will, O God, be done! If it can glorify Thy name, make a way of escape for Thy people! Deliver us from the heathen around about us. They have appointed us unto death; but Thine arm can bring salvation.” These are all the words which I can bring to mind. All seemed to have a deep sense of their unworthiness and manifested entire submission to the will of God; yet, like Jacob, every one, without an exception, was earnestly pleading and wrestling for deliverance. EW …
"And when they had prayed, the place was shaken where they were assembled together; and they were all filled with the Holy Ghost, and they spake the word of God with boldness."
Both passages describe a group of believers praying earnestly to God in a time of persecution or difficulty. While the specific wording differs, the overall theme of fervent prayer for deliverance is present in both.
"Soon after they had commenced their earnest cry, the angels, in sympathy, desired to go to their deliverance. But a tall, commanding angel suffered them not. He said, “The will of God is not yet fulfilled. They must drink of the cup. They must be baptized with the baptism.” EW 272.2"
"But Jesus answered and said, Ye know not what ye ask. Are ye able to drink of the cup that I shall drink of, and to be baptized with the baptism that I am baptized with? They say unto him, We are able."
EGW uses the phrases 'drink of the cup' and 'baptized with the baptism,' which are directly taken from Jesus's words in Matthew 20:22. The context of suffering and divine will is also shared.
Soon I heard the voice of God, which shook the heavens and the earth. There was a mighty earthquake. Buildings were shaken down on every side. I then heard a triumphant shout of victory, loud, musical, and clear. I looked upon the company, who, a short time before, were in such distress and bondage. Their captivity was turned. A glorious light shone upon them. How beautiful they then looked! All marks of care and weariness were gone, and health and beauty were seen in every countenance. Their enemies, the heathen around them, fell like dead men; they could not endure the light that shone upon the delivered, holy ones. This light and glory remained upon them, until Jesus was seen in the clouds of heaven, and the faithful, tried company were changed in a moment, in the twinkling of an eye, from glory to glory. And the graves were opened, and the saints came forth, clothed with immortality, crying, “Victory over death and the grave”; and together with the living saints they were caught up…
"And when they had prayed, the place was shaken where they were assembled together; and they were all filled with the Holy Ghost, and they spake the word of God with boldness."
Both passages describe a shaking and a powerful event associated with God's presence and the empowerment of believers. While the details differ, the core theme of divine intervention accompanied by physical upheaval is present in both.