A: 

One thing that you could do is look at recent transfers of similar(1) players. Say all transfers within 2-5 game weeks of similar players and then take the average (or median or some other calculated value) of their sale price.

(1) You will have to define similiar in some way, i.e a defender with +-10 in defence, +-3 in passing and +-2 years of age. More factors give more precise results.

Runeborg
Thank you. Taking the average seems to be a good idea. I read this somewhere: "The market value is simply the average of all selling prices of players with the same combination of strength, maximal strength, motivation and age." But how could I code this (for example in PHP)? I can't do (1) for every combination ...
You could make this very easy by just searching for all players with +-2 of all stats and averaging their transfer price. Another way of doing it generically could be to adjust the variance depending on the dominating abilities. So if a players strongest stat is passing, then you use +-4, +-3 for the second strongest and +-2 for the rest. You can do the same thing with age intervals since this can affect price alot as well. You may want to use a smaller age span for young players than for players in their mid-career.
Runeborg
You can do this easily in a simple query as well: SELECT AVG(transferPrice) FROM Transfers WHERE passing > @pass-2 AND passing < @pass+2 AND ...
Runeborg
But this would be very complicated, wouldn't it? I would have to do that for every single player ...
Well yes, or you could do it for some preset skill levels and choose whoever is closest to the player you want to compare for if you want to batch it up.
Runeborg
+5  A: 

My suggestion: define a distance function that takes two players stats and return a distance value. Now that you have a distance between the two (that corresponds to the similarity between them) you can use the K-means algorithm to find clusters of similar players.

For each cluster you can take a number of values that can help you calculate the so called 'market price' (like the average or median value).

Here's a very simple example of how you could compute the distance function between two players:

float distance(Player player1, Player player2){
    float distance = 0.0;

    distance += abs(player1.strength - player2.strength) / strengthRange;
    distance += abs(player1.maxStrength - player2.maxStrength) / maxStrength;
    distance += abs(player1.motivation - player2.motivation) / motivationRange;
    distance += abs(player1.age - player2.age) / ageRange;

    return distance;
}

Now that you have the distance function you can apply the k-means algorithm:

  1. Assign each player randomly to a cluster.

  2. Now compute the centroid of each cluster. In your case the centroid coordinates will be (strength, maxStrength, motivation, age). To compute the centroid strength coordinate, for example, just average the strengths for the all players in the cluster.

  3. Now assign each player to the nearest centroid. Note that in this step some players may have its cluster changed.

  4. Repeat steps 2 and 3 until you have convergence or, in other words, until no player have its cluster changed in step 3.

Now that you have the clusters, you can calculate the average price fore similar players.

Alceu Costa
+1 nice idea ______
Stefano Borini
Thank you very much! "The market value is simply the average of all selling prices of players with the same combination of strength, maximal strength, motivation and age." So I have to code a distance function and all players within a given distance go to one group, right? Can I fill in all the data into a matrix? If I have the clusters, I just take the average of the prices.
Thank you very much for this detailed edit. :) I've still some questions: How do I decide which centroid is the nearest one? The centroids have 4 coordinates as you said. And how many clusters should I build? Or doesn't this matter since I repeat it until convergence?
To find the nearest centroid: just compute the distance from all the centroids and get the smallest value. There are data structures that would make that search more efficient, like the R-Tree, that's used for spatial access methods, but I don't think that you need that... The number of clusters is up to you to decide, but note that if you get a number that's too high you may get a poor result (like only one player in a cluster). I have seen games were players are divided into 5 categories (like 1 to 5 stars), but that's just an idea...
Alceu Costa
Thanks. But to calculate the distance between a player and a centroid, I need four coordinates of the centroid since the distance function takes four parameters, right? How do I get these four coordinates? By averaging the coordinates of all players in that cluster? For example: Cluster [(1,2,3,4),(2,3,4,5),(8,4,2,8)] has the centroid (3.6, 3, 3, 5.6). Is this correct?
Yes, that's right.
Alceu Costa
Thank you very much! Last question: I've coded your approach (see edit in the question). But it doesn't work correctly. All players go to the same cluster. Why? Where's the mistake? I've also tried this with other cluster sizes and numbers of players ...
It's hard to me to find out what is wrong with your code because I have never worked with PHP. However, there's something strange about your output: in each iteration (round) 25 players had its cluster changed. I would expect different numbers for each iteration. Another point: your code always perform 3 iterations (look at 'for' loop at the end), when the correct would be to iterate while no player have its cluster changed.
Alceu Costa
I'll ask this as a new question. Thank you very much for your approach!
A: 

Or you could use a little Economics 101 and try to define the supply and demand for that specific player based on:

  • Number of players in the league with similar capabilities (you could use the clustering method mentioned before) and number of those players "available" for transfer
  • Number of teams that own the players with similar capabilities and number of teams that are in need for such players

Now with these number you could calculate the supply (available players for transfer) and demand (teams in need for those players) and use that to modify your base price (which can be your last transfer price or a base price for a player) up or down (ie more demand than supply will tend to push the prices up and vice versa)

After that it becomes negotiation game where you can take a look at some of the Game Theory literature to solve the actual exchange price.

Hope this at least give you a different look into it.

Jaime