'Encoding' in the text book is very generic term. To be honest, I haven't seen many cases people using this term in such a generic term in the field. Personally I think it is because it might not have been clearly defined at the beginning or so many diverse type of encoding technology came out and the definition got more fuzzy now. Even when people use the term 'Encoding', they tend to use it in a very specific context. So you don't get clear idea of the context in which the term is used, you might not clearly understand what it realy mean.
In this page, I will try to explain the term 'Encoding' in a generic term because it is how the term is described in many text book.
In very generic form, 'Encoding' can be described as in the following diagram. Encoding is a process (or technique) to convert 'one form of Thing' into 'another form of thing'.
Now the question is what do you mean by 'Thing' in the above description. It would be even more difficult to define this 'Thing' because there are so many different kind of 'Things' that can be plug into this statement. The most practical way is just to see a lot of examples. However, in most textbook they tried to categorize the 'Thing' into two large groups called 'Digital' and 'Analog'. Using all the possible combination of the two category, they categorize the type of encoders into roughly 4 types as below.
Let's briefly think of what each of these type mean. Actually each one of these topics are huge topic and almost impossible to describe it clearly with a few lines. So don't get disappointed even if you don't understand this description clearly just by reading this page.
Analog Data => Analog Signal : This is to convert one form of analog signal to another form of analog signal. Some example of this type are AM (Amplitude Modulation), FM(Frequency Modulation) and PM(Phase Modulation) etc. One typical example for this would be in AM / FM radio broadcasting. When people talk in a microphone, the sound wave is a Analog data and when it goes through the communication system, it converted (Encoded) into AM or FM electrical signal (Of course, you would need further study to understand what AM / FM mean).
Analog Data => Digital Signal : This is to convert an analog data to a digital signal. This is often called 'Digitization'. Typical example of this type is PCM (Pulse Code Modulation).
Digital Data => Analog Signal : This is to convert a digital form of data into Analog form of signal. Typical examples of this type are ASK(Amplitude Shift Keying), FSK(Frequency Shift Keying) and PSK(Phase Shift Keying).
Digital Data => Digital Signal : This is to convert a digital data to a digital signal. Typical examples of this types are RZ / NRZ, Menchester Coding, Bipolar AMI, B8ZS, Block Coding (3B/4B, 5B/6B, 8B/10B) etc. These are widely used in Digital communication over wireline.
Why Encoding ?