What spirit(s) is referred to in 1 John 4? 1 John 4:1-6 (NIV):


  Dear friends, do not believe every spirit, but test the spirits to
  see whether they are from God, because many false prophets have gone
  out into the world. 2 This is how you can recognize the Spirit of God:
  Every spirit that acknowledges that Jesus Christ has come in the flesh
  is from God, 3 but every spirit that does not acknowledge Jesus is not
  from God. This is the spirit of the antichrist, which you have heard
  is coming and even now is already in the world.
  
  4 You, dear children, are from God and have overcome them, because the
  one who is in you is greater than the one who is in the world. 5 They
  are from the world and therefore speak from the viewpoint of the
  world, and the world listens to them. 6 We are from God, and whoever
  knows God listens to us; but whoever is not from God does not listen
  to us. This is how we recognize the Spirit[a] of truth and the spirit
  of falsehood.


What spirit is being referred to here? Is this the collective spirit of the world vs. the spirit of God? Is this a reference to demons vs. angelic messengers of truth? Or is this the spirit of man vs. true prophets? 

Which scriptures can be compared in the proper context to show the accurate meaning of this passage?
In verses 1–3, John speaks first of the "spirit of God VS the "spirit of antichrist".  In verses 4–6 he speaks of the "spirit of truth" VS the "spirit of falsehood" ("error" in KJV). These are the same two spirits; the restating of same concept in different terms is common in OT and NT. So the spirit of God is the spirit of truth, and the spirit of antichrist is the spirit of falsehood.  In other places, the devil/Lucifer is referred to as the father of lies:
John 8:44
      Ye are of your father the devil, and the lusts of your father ye will do. He was a murderer from the beginning, and abode not in the truth, because there is no truth in him. When he speaketh a lie, he speaketh of his own: for he is a liar, and the father of it.

So yes, you could say that the devil (and his demons, if you believe in such) have the spirit of lies.